Skip to content

Commit

Permalink
Add alias to kouryaku command
Browse files Browse the repository at this point in the history
  • Loading branch information
DoumanAsh committed Sep 6, 2018
1 parent f09915c commit b632c34
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bot/src/command/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ impl Command {
Some(arg) => Some(Command::DelVn(DelVn{ title: arg.as_str().trim().to_string()})),
None => Some(Command::Text("For which VN...?".into()))
},
Some("kouryaku") => match captures.get(ARG_IDX) {
Some("k") | Some("walk") | Some("kouryaku") => match captures.get(ARG_IDX) {
Some(arg) => Some(Command::Kouryaku(Kouryaku{ title: arg.as_str().trim().to_string()})),
None => Some(Command::Text("For which VN...?".into()))
},
Expand Down
2 changes: 1 addition & 1 deletion bot/src/discord.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ pub fn client(executor: actix::Addr<actors::exec::Executor>, kouryaku_addr: acti
.exec(set_hook)
})
.command("del_vn", |config| config.desc("Remove VN").exec(del_vn))
.command("kouryaku", |config| config.desc("Find walkthrough for VN").exec(kouryaku));
.command("kouryaku", |config| config.desc("Find walkthrough for VN").exec(kouryaku).known_as("walk").known_as("k"));

client.with_framework(framework);

Expand Down

0 comments on commit b632c34

Please sign in to comment.