-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(connector): [Adyen] Add support for PIX Payment Method #3236
Conversation
#[serde(rename_all = "snake_case")] | ||
#[serde(untagged)] | ||
pub enum QrCodeInformation { | ||
QrCodeUrl { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add comments stating that the enum order shouldn't be changed as this is being used during serialization and deserialization
.action | ||
.qr_code_url | ||
.clone() | ||
.ok_or(errors::ConnectorError::ResponseHandlingFailed)?; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why we are throwing error incase of None? This is an optional field from connector
display_to_timestamp: None, | ||
}; | ||
let qr_code_instructions = payments::NextActionFromConnectorMetaData::QrCodeInformation( | ||
payments::QrCodeInformation::QrCodeUrl { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Based on the data available, please construct QrCodeInformation::QrCodeUrl or QrCodeInformation::QrDataUrl or QrCodeInformation::QrCodeImageUrl.
payments::QrCodeInformation::QrCodeUrl { | ||
image_data_url, | ||
qr_code_url, | ||
display_to_timestamp: None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't we get expiration time limit for the QR code from Aden?
}, | ||
api_models::payments::NextActionFromConnectorMetaData::QrCodeInformation (qr_info) => { | ||
|
||
match qr_info { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move this to from implementation
6beac53
Type of Change
Description
Additional Changes
Motivation and Context
How did you test it?
Checklist
cargo +nightly fmt --all
cargo clippy