Skip to content

Commit

Permalink
Update RequestHeaders: add Sec-Fetch-{Dest,Mode,Site,User} in sta…
Browse files Browse the repository at this point in the history
…ndards (#145)
  • Loading branch information
kanarus authored May 3, 2024
1 parent 18f662b commit e484513
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions ohkami/src/request/headers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ macro_rules! Header {
)*
}
};
} Header! {42;
} Header! {46;
Accept: b"Accept" | b"accept",
AcceptEncoding: b"Accept-Encoding" | b"accept-encoding",
AcceptLanguage: b"Accept-Language" | b"accept-language",
Expand Down Expand Up @@ -239,6 +239,10 @@ macro_rules! Header {
ProxyAuthorization: b"Proxy-Authorization" | b"proxy-authorization",
Range: b"Range" | b"range",
Referer: b"Referer" | b"referer",
SecFetchDest: b"Sec-Fetch-Dest" | b"sec-fetch-dest",
SecFetchMode: b"Sec-Fetch-Mode" | b"sec-fetch-mode",
SecFetchSite: b"Sec-Fetch-Site" | b"sec-fetch-site",
SecFetchUser: b"Sec-Fetch-User" | b"sec-fetch-user",
SecWebSocketExtensions: b"Sec-WebSocket-Extensions" | b"sec-websocket-extensions",
SecWebSocketKey: b"Sec-WebSocket-Key" | b"sec-websocket-key",
SecWebSocketProtocol: b"Sec-WebSocket-Protocol" | b"sec-websocket-protocol",
Expand Down Expand Up @@ -399,15 +403,14 @@ impl Headers {
pub(crate) fn init() -> Self {
Self {
standard: Box::new([
None, None, None, None, None,
None, None, None, None, None,
None, None, None, None, None,
None, None, None, None, None,
None, None, None, None, None,
None, None, None, None, None,
None, None, None, None, None,
None, None, None, None, None,
None, None,
None, None, None, None, None, None,
None, None, None, None, None, None,
None, None, None, None, None, None,
None, None, None, None, None, None,
None, None, None, None, None, None,
None, None, None, None, None, None,
None, None, None, None, None, None,
None, None, None, None,
]),
custom: None,
}
Expand Down

0 comments on commit e484513

Please sign in to comment.