fix(refund_sync): add validation for missing connector_refund_id (#1013)

This commit is contained in:
Nishant Joshi
2023-05-03 01:57:14 +05:30
committed by GitHub
parent e9fc34ff62
commit 4397c8e199
6 changed files with 45 additions and 9 deletions

View File

@ -292,6 +292,7 @@ pub trait RefundsRequestData {
}
impl RefundsRequestData for types::RefundsData {
#[track_caller]
fn get_connector_refund_id(&self) -> Result<String, Error> {
self.connector_refund_id
.clone()
@ -373,6 +374,7 @@ impl CardData for api::Card {
}
}
#[track_caller]
fn get_card_issuer(card_number: &str) -> Result<CardIssuer, Error> {
for (k, v) in CARD_REGEX.iter() {
let regex: Regex = v