Skip to content

Commit

Permalink
fix(core): compression: use short name br
Browse files Browse the repository at this point in the history
  • Loading branch information
fundon committed Sep 30, 2022
1 parent e1e6822 commit fea2a52
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions viz-core/src/middleware/compression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ impl FromStr for ContentCoding {
Ok(ContentCoding::Deflate)
} else if s.eq_ignore_ascii_case("gzip") {
Ok(ContentCoding::Gzip)
} else if s.eq_ignore_ascii_case("brotli") {
} else if s.eq_ignore_ascii_case("br") {
Ok(ContentCoding::Brotli)
} else if s == "*" {
Ok(ContentCoding::Any)
Expand All @@ -136,7 +136,7 @@ impl From<ContentCoding> for &'static str {
match cc {
ContentCoding::Gzip => "gzip",
ContentCoding::Deflate => "deflate",
ContentCoding::Brotli => "brotli",
ContentCoding::Brotli => "br",
ContentCoding::Any => "*",
}
}
Expand Down

0 comments on commit fea2a52

Please sign in to comment.