From 8b0a1490dba5d16d38f9f50fa42520042ff9332f Mon Sep 17 00:00:00 2001 From: Shagnor Date: Sun, 15 Jan 2023 13:53:40 +1100 Subject: [PATCH] Fix error message. --- blastmud_game/src/message_handler/user_commands/login.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blastmud_game/src/message_handler/user_commands/login.rs b/blastmud_game/src/message_handler/user_commands/login.rs index cdfcf50..d60f5bb 100644 --- a/blastmud_game/src/message_handler/user_commands/login.rs +++ b/blastmud_game/src/message_handler/user_commands/login.rs @@ -8,7 +8,7 @@ pub struct Verb; impl UserVerb for Verb { async fn handle(self: &Self, ctx: &mut VerbContext, _verb: &str, remaining: &str) -> UResult<()> { let (username, password) = match remaining.split_whitespace().collect::>()[..] { - [] => user_error("Too few options to login".to_owned())?, + [] | [_] => user_error("Too few options to login".to_owned())?, [username, password] => (username, password), _ => user_error("Too many options to login".to_owned())?, };