mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 17:19:15 +08:00
chore: address Rust 1.66 clippy lints (#162)
This commit is contained in:
@ -617,7 +617,7 @@ impl api::IncomingWebhook for Adyen {
|
|||||||
|
|
||||||
let response: adyen::AdyenResponse = notif.into();
|
let response: adyen::AdyenResponse = notif.into();
|
||||||
|
|
||||||
let res_json = serde_json::to_value(&response)
|
let res_json = serde_json::to_value(response)
|
||||||
.into_report()
|
.into_report()
|
||||||
.change_context(errors::ConnectorError::WebhookResourceObjectNotFound)?;
|
.change_context(errors::ConnectorError::WebhookResourceObjectNotFound)?;
|
||||||
|
|
||||||
|
|||||||
@ -861,7 +861,7 @@ impl api::IncomingWebhook for Stripe {
|
|||||||
.ok_or(errors::ConnectorError::WebhookSignatureNotFound)
|
.ok_or(errors::ConnectorError::WebhookSignatureNotFound)
|
||||||
.into_report()?;
|
.into_report()?;
|
||||||
|
|
||||||
hex::decode(&signature)
|
hex::decode(signature)
|
||||||
.into_report()
|
.into_report()
|
||||||
.change_context(errors::ConnectorError::WebhookSignatureNotFound)
|
.change_context(errors::ConnectorError::WebhookSignatureNotFound)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -26,8 +26,8 @@ pub struct ConnectorPTMapping {
|
|||||||
pub max_retries_count: i32,
|
pub max_retries_count: i32,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl ConnectorPTMapping {
|
impl Default for ConnectorPTMapping {
|
||||||
pub fn default() -> Self {
|
fn default() -> Self {
|
||||||
Self {
|
Self {
|
||||||
custom_merchant_mapping: HashMap::new(),
|
custom_merchant_mapping: HashMap::new(),
|
||||||
default_mapping: RetryMapping {
|
default_mapping: RetryMapping {
|
||||||
|
|||||||
@ -160,7 +160,7 @@ pub async fn get_batches(
|
|||||||
})?;
|
})?;
|
||||||
metrics::BATCHES_CONSUMED.add(&metrics::CONTEXT, 1, &[]);
|
metrics::BATCHES_CONSUMED.add(&metrics::CONTEXT, 1, &[]);
|
||||||
|
|
||||||
let (batches, entry_ids): (Vec<Vec<ProcessTrackerBatch>>, Vec<Vec<String>>) = response.into_iter().map(|(_key, entries)| {
|
let (batches, entry_ids): (Vec<Vec<ProcessTrackerBatch>>, Vec<Vec<String>>) = response.into_values().map(|entries| {
|
||||||
entries.into_iter().try_fold(
|
entries.into_iter().try_fold(
|
||||||
(Vec::new(), Vec::new()),
|
(Vec::new(), Vec::new()),
|
||||||
|(mut batches, mut entry_ids), entry| {
|
|(mut batches, mut entry_ids), entry| {
|
||||||
|
|||||||
Reference in New Issue
Block a user