-
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
refactor(connector): [AIRWALLEX, MULTISAFEPAY, RAZORPAY, SHIFT4, WORLDPAY, ZSL] Move connectors from router
to hyperswitch_connectors
crate
#6369
Conversation
.as_ref() | ||
.and_then(|billing_address| billing_address.get_optional_full_name()) | ||
} | ||
} | ||
pub trait PaymentsPreProcessingRequestData { |
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.
pub trait PaymentsPreProcessingRequestData { | |
pub trait PaymentsPreProcessingData { |
Rename this trait to PaymentsPreProcessingData
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.
Another struct with the name PaymentsPreProcessingData already exists in [router_request_types.rs] file
So upon renaming the trait PaymentsPreProcessingRequestData to this name, it gives an error
/// Worldpay's unique reference ID for a request TODO: Move to hyperswitch_connectors/constants once Worldpay is moved to connectors crate | ||
pub const WP_CORRELATION_ID: &str = "WP-CorrelationId"; |
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 const definition to crates/hyperswitch_connectors/src/connectors/worldpay/transformers.rs
crates/router/src/core/utils.rs
Outdated
@@ -1310,7 +1310,7 @@ pub fn get_connector_label( | |||
format!("{connector_name}_{business_country}_{business_label}"); | |||
|
|||
// Business sub label is currently being used only for cybersource | |||
// To ensure backwards compatibality, cybersource mca's created before this change | |||
// To ensure backwards compatibality, cybersource mca's created be this change |
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 is this done? Remove this change if not required.
connectors::Zen, | ||
connectors::Zsl, |
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.
Values for default_imp_for_calculate_tax
are not sorted alphabetically.
router
to hyperswitch_connectors
crate
crates/hyperswitch_connectors/src/connectors/worldpay/transformers.rs
Outdated
Show resolved
Hide resolved
strum = { version = "0.26", features = ["derive"] } | ||
time = "0.3.35" | ||
url = "2.5.0" | ||
urlencoding = "2.1.3" |
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.
Can we confirm if we can use the url_encode()
utility method instead of the urlencoding
crate?
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.
This function url_encode()
supports serialization only for maps and structs, hence we cannot use this.
268ccc1
a39899e
Type of Change
Description
Moved connector Airwallex, Multisafepay, Razorpay, Shift4, Worldpay and Zsl from Router crate to hyperswitch_connectors crate.
Additional Changes
Motivation and Context
How did you test it?
Multisafepay
Request
Response
Request
Response
Shift4
Request
Response
Checklist
cargo +nightly fmt --all
cargo clippy