From 29f89fd3257ca2c114f6cf3e2cb577ea68cfba63 Mon Sep 17 00:00:00 2001 From: p11 Date: Sun, 16 Jul 2023 16:44:47 +0200 Subject: [PATCH] Removed unwrap in request handler --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 74caf79..f1368df 100644 --- a/src/main.rs +++ b/src/main.rs @@ -132,7 +132,7 @@ impl Context { let mut text_buf = Vec::new(); convert(decoded_text.lines(), &mut text_buf); let text = std::str::from_utf8(text_buf.as_slice()) - .unwrap() + .unwrap_or_default() .to_string(); local_comments.push(Comment { name, text });