Skip to content

Commit

Permalink
chore(codec): Use BytesMut put_u8 method to write single byte (#1774)
Browse files Browse the repository at this point in the history
  • Loading branch information
tottoto authored Jul 6, 2024
1 parent 2cc868f commit 4dda0a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tonic/src/codec/compression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ impl EnabledCompressionEncodings {
let mut value = BytesMut::new();
for encoding in self.inner.into_iter().flatten() {
value.put_slice(encoding.as_str().as_bytes());
value.put_slice(b",");
value.put_u8(b',');
}

if value.is_empty() {
Expand Down

0 comments on commit 4dda0a9

Please sign in to comment.