mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 17:19:15 +08:00
refactor: return optional request body from build_request_v2 in ConnectorIntegrationV2 trait (#5865)
This commit is contained in:
@ -152,6 +152,11 @@ impl RequestBuilder {
|
||||
self
|
||||
}
|
||||
|
||||
pub fn set_optional_body<T: Into<RequestContent>>(mut self, body: Option<T>) -> Self {
|
||||
body.map(|body| self.body.replace(body.into()));
|
||||
self
|
||||
}
|
||||
|
||||
pub fn set_body<T: Into<RequestContent>>(mut self, body: T) -> Self {
|
||||
self.body.replace(body.into());
|
||||
self
|
||||
|
||||
Reference in New Issue
Block a user