Skip to content

Commit

Permalink
change to register_command
Browse files Browse the repository at this point in the history
  • Loading branch information
braindigitalis committed Oct 21, 2024
1 parent 72ab773 commit a336e27
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/userapptest/userapp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,10 @@ int main() {
}
});

bot.on_slashcommand([](const auto& e) {
bot.register_command("userapp", [](const dpp::slashcommand_t& e) {
/**
* Simple test output that shows the context of the command
*/
if (e.command.get_command_name() != "userapp") {
return;
}
e.reply("This is the `/userapp` command." + std::string(
e.command.is_user_app_interaction() ?
" Executing as a user interaction owned by user: <@" + e.command.get_authorizing_integration_owner(dpp::ait_user_install).str() + ">" :
Expand Down

0 comments on commit a336e27

Please sign in to comment.