Skip to content

Commit

Permalink
chore: Resolved PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Debarshi Gupta authored and Debarshi Gupta committed Dec 18, 2024
1 parent ff8f7ee commit e49115d
Show file tree
Hide file tree
Showing 3 changed files with 175 additions and 157 deletions.
7 changes: 3 additions & 4 deletions crates/hyperswitch_connectors/src/connectors/deutschebank.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use std::time::SystemTime;

use actix_web::http::header::Date;
use base64::Engine;
use common_enums::enums;
use common_enums::{enums, PaymentMethod};
use common_utils::{
errors::CustomResult,
ext_traits::BytesExt,
Expand Down Expand Up @@ -124,7 +124,7 @@ impl ConnectorCommon for Deutschebank {
}

fn get_currency_unit(&self) -> api::CurrencyUnit {
api::CurrencyUnit::Base
api::CurrencyUnit::Minor
}

fn common_get_content_type(&self) -> &'static str {
Expand Down Expand Up @@ -471,7 +471,7 @@ impl ConnectorIntegration<CompleteAuthorize, CompleteAuthorizeData, PaymentsResp
"preauthorization"
};

if req.is_three_ds() {
if req.is_three_ds() && matches!(req.payment_method, PaymentMethod::Card) {
Ok(format!(
"{}/services/v2.1//headless3DSecure/event/{event_id}/final",
self.base_url(connectors)
Expand All @@ -494,7 +494,6 @@ impl ConnectorIntegration<CompleteAuthorize, CompleteAuthorizeData, PaymentsResp
req.request.minor_amount,
req.request.currency,
)?;

let connector_router_data = deutschebank::DeutschebankRouterData::from((amount, req));
let connector_req =
deutschebank::DeutschebankCompleteAuthorizeRequest::try_from(&connector_router_data)?;
Expand Down
Loading

0 comments on commit e49115d

Please sign in to comment.