mirror of
				https://github.com/juspay/hyperswitch.git
				synced 2025-10-31 18:17:13 +08:00 
			
		
		
		
	fix: duplication check fix in basilisk-hs (#881)
This commit is contained in:
		 Sangamesh Kulkarni
					Sangamesh Kulkarni
				
			
				
					committed by
					
						 GitHub
						GitHub
					
				
			
			
				
	
			
			
			 GitHub
						GitHub
					
				
			
						parent
						
							9f90b888c8
						
					
				
				
					commit
					b12762e776
				
			| @ -316,7 +316,10 @@ pub async fn add_card_hs( | |||||||
|         req, |         req, | ||||||
|         merchant_id, |         merchant_id, | ||||||
|     ); |     ); | ||||||
|     Ok((payment_method_resp, store_card_payload.duplicate)) |     Ok(( | ||||||
|  |         payment_method_resp, | ||||||
|  |         store_card_payload.duplicate.unwrap_or(false), | ||||||
|  |     )) | ||||||
| } | } | ||||||
|  |  | ||||||
| // Legacy Locker Function | // Legacy Locker Function | ||||||
| @ -586,7 +589,7 @@ pub async fn mock_add_card_hs( | |||||||
|         .change_context(errors::VaultError::SaveCardFailed)?; |         .change_context(errors::VaultError::SaveCardFailed)?; | ||||||
|     let payload = payment_methods::StoreCardRespPayload { |     let payload = payment_methods::StoreCardRespPayload { | ||||||
|         card_reference: response.card_id, |         card_reference: response.card_id, | ||||||
|         duplicate: false, |         duplicate: Some(false), | ||||||
|     }; |     }; | ||||||
|     Ok(payment_methods::StoreCardResp { |     Ok(payment_methods::StoreCardResp { | ||||||
|         status: "SUCCESS".to_string(), |         status: "SUCCESS".to_string(), | ||||||
|  | |||||||
| @ -44,7 +44,7 @@ pub struct StoreCardResp { | |||||||
| #[derive(Debug, Deserialize, Serialize)] | #[derive(Debug, Deserialize, Serialize)] | ||||||
| pub struct StoreCardRespPayload { | pub struct StoreCardRespPayload { | ||||||
|     pub card_reference: String, |     pub card_reference: String, | ||||||
|     pub duplicate: bool, |     pub duplicate: Option<bool>, | ||||||
| } | } | ||||||
|  |  | ||||||
| #[derive(Debug, Deserialize, Serialize)] | #[derive(Debug, Deserialize, Serialize)] | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user