Fix error message.
This commit is contained in:
parent
cf8ceb1351
commit
8b0a1490db
@ -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::<Vec<&str>>()[..] {
|
||||
[] => 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())?,
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user