From 449c29a0f366f30cf798c10d104afe2f4ab7dd05 Mon Sep 17 00:00:00 2001 From: larzie Date: Thu, 28 Nov 2024 18:19:33 +0300 Subject: [PATCH] warning fix --- server/esp/src/types/fast_string.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/esp/src/types/fast_string.rs b/server/esp/src/types/fast_string.rs index 9f726f2fe..a175eb91e 100644 --- a/server/esp/src/types/fast_string.rs +++ b/server/esp/src/types/fast_string.rs @@ -295,8 +295,8 @@ impl FastString { /// Converts the string to a `&str`, bypassing utf-8 validation checks #[inline] - pub unsafe fn to_str_unchecked(&self) -> &str { - std::str::from_utf8_unchecked(self.as_bytes()) + pub fn to_str_unchecked(&self) -> &str { + unsafe std::str::from_utf8_unchecked(self.as_bytes()) } /// Converts the string to a `&str`, returns """ if utf-8 validation fails