From c7a6955565d3ee9a3c67746cd919118a921b91a3 Mon Sep 17 00:00:00 2001 From: IsseW Date: Sat, 18 Jun 2022 15:25:55 +0200 Subject: [PATCH] fix --- voxygen/src/cmd.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/voxygen/src/cmd.rs b/voxygen/src/cmd.rs index 96f422e3df..3cd0200ffd 100644 --- a/voxygen/src/cmd.rs +++ b/voxygen/src/cmd.rs @@ -339,7 +339,7 @@ pub fn complete(line: &str, client: &Client, cmd_prefix: char) -> Vec { if line.starts_with(cmd_prefix) { let line = line.strip_prefix(cmd_prefix).unwrap_or(line); let mut iter = line.split_whitespace(); - let cmd = iter.next().unwrap(); + let cmd = iter.next().unwrap_or(""); let i = iter.count() + if word.is_empty() { 1 } else { 0 }; if i == 0 { // Completing chat command name. This is the start of the line so the prefix