feat(import): preserve supported HTTP contracts
This commit is contained in:
1 parent
083974c27f
commit
f8ee7c9bfe
87 files changed
+7496
-534
No files matched your search
@@ -51,6 +51,8 @@ pub struct PreparedRequest {
|
||||
pub trusted_header_names: BTreeSet<String>,
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub body: Option<serde_json::Value>,
|
||||
#[serde(default, skip_serializing_if = "Option::is_none")]
|
||||
pub body_content_type: Option<String>,
|
||||
#[serde(default)]
|
||||
pub timeout_ms: u64,
|
||||
}
|
||||
@@ -72,6 +74,7 @@ impl From<PreparedRequest> for crank_core::PreparedRequest {
|
||||
headers: value.headers,
|
||||
trusted_header_names: value.trusted_header_names,
|
||||
body: value.body,
|
||||
body_content_type: value.body_content_type,
|
||||
timeout_ms: value.timeout_ms,
|
||||
}
|
||||
}
|
||||
@@ -85,6 +88,7 @@ impl From<crank_core::PreparedRequest> for PreparedRequest {
|
||||
headers: value.headers,
|
||||
trusted_header_names: value.trusted_header_names,
|
||||
body: value.body,
|
||||
body_content_type: value.body_content_type,
|
||||
timeout_ms: value.timeout_ms,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user