Commit 64e4f67e43

64e4f67e43493dc0832600dc84931aee8b28105d

parent: a18d0f54eb

Unregistered key

mordquist <16607572+mordquist@users.noreply.github.com> · 2024-05-25 22:53 UTC
committer: <noreply@github.com>

Add error for missing username on `:logout` (#277)

Layout: unified · split

src/commands.rs +3
@@ -515,6 +515,9 @@ fn iamb_open(desc: CommandDescription, ctx: &mut ProgContext) -> ProgResult {
515515fn iamb_logout(desc: CommandDescription, ctx: &mut ProgContext) -> ProgResult {
516516 let args = desc.arg.strings()?;
517517
518 if args.is_empty() {
519 return Result::Err(CommandError::Error("Missing username".to_string()));
520 }
518521 if args.len() != 1 {
519522 return Result::Err(CommandError::InvalidArgument);
520523 }