From 7f74edc8d8e8c7291d8552b4bf6d02a89e911f46 Mon Sep 17 00:00:00 2001 From: rust-learn-now Date: Wed, 13 Nov 2024 11:23:51 +0800 Subject: [PATCH] [ISSUE #39]Fix serde Serialize error --- src/serde.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/serde.rs b/src/serde.rs index d5b391a..f0c4a78 100644 --- a/src/serde.rs +++ b/src/serde.rs @@ -11,6 +11,7 @@ impl Serialize for CheetahString { match &self.inner { InnerString::ArcString(s) => serializer.serialize_str(s.as_str()), InnerString::StaticStr(s) => serializer.serialize_str(s), + InnerString::ArcVecString(s) => serializer.serialize_bytes(s), #[cfg(feature = "bytes")] InnerString::Bytes(bytes) => serializer.serialize_bytes(bytes.as_ref()), InnerString::Empty => serializer.serialize_bytes(&[]),