Skip to content

Commit bbfdf43

Browse files
committed
f Move content-type to const
1 parent 0be0a1d commit bbfdf43

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/client.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ use crate::util::retry::{retry, RetryPolicy};
1616
use crate::util::KeyValueVecKeyPrinter;
1717

1818
const APPLICATION_OCTET_STREAM: &str = "application/octet-stream";
19+
const CONTENT_TYPE: &str = "content-type";
1920
const DEFAULT_TIMEOUT_SECS: u64 = 10;
2021
const MAX_RESPONSE_BODY_SIZE: usize = 1024 * 1024 * 1024; // 1GB
2122
const DEFAULT_CLIENT_CAPACITY: usize = 10;
@@ -198,7 +199,7 @@ impl<R: RetryPolicy<E = VssError>> VssClient<R> {
198199
.map_err(|e| VssError::AuthError(e.to_string()))?;
199200

200201
let http_request = bitreq::post(url)
201-
.with_header("content-type", APPLICATION_OCTET_STREAM)
202+
.with_header(CONTENT_TYPE, APPLICATION_OCTET_STREAM)
202203
.with_headers(headers)
203204
.with_body(request_body)
204205
.with_timeout(DEFAULT_TIMEOUT_SECS)

0 commit comments

Comments
 (0)