aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/src/io/base_io.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/shirabe/src/io/base_io.rs')
-rw-r--r--crates/shirabe/src/io/base_io.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/shirabe/src/io/base_io.rs b/crates/shirabe/src/io/base_io.rs
index 6e6e7d0..f2b7ee5 100644
--- a/crates/shirabe/src/io/base_io.rs
+++ b/crates/shirabe/src/io/base_io.rs
@@ -446,11 +446,11 @@ pub trait BaseIO: IOInterface {
let mut message_str = message.as_string().unwrap_or("").to_string();
if !context.is_empty() {
- let json = Silencer::call(|| {
- json_encode_ex(
+ let json: anyhow::Result<Option<String>> = Silencer::call(|| {
+ Ok(json_encode_ex(
&PhpMixed::Array(context.clone()),
JSON_INVALID_UTF8_IGNORE | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE,
- )
+ ))
});
if let Ok(Some(json_str)) = json {
message_str += " ";