-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make /coin check
default to the caller
#282
Conversation
`/coin check` originally had a mandatory argument of a target user to check the balance of. Now the argument defaults to the user who called the command, making it more ergonomic to use.
Also please leave screenshots :)) |
- Also generalizes getUserIDFromMessage to just get the User straight up - Updated previou references where relevant (leaderboard) - Replaces "`user` has" with `You have` if the user is calling `/coin check` on their own
Decided to remove the (added screenshots too) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
small changes
- `'b', 'bal', 'balance'` due to the removal of the balance subcommand
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Feel free to merge after you fix the linter.
Fixed the linter, but don't have write access 🙈 |
Related Issues
N/A
Summary of Changes
In comparison to
.coin
, doing/coin check
and having to look for the target user was pretty time consuming when somebody just wanted to check their own balance. This PR makes theuser
argument optional and defaults to checking the balance of the user who called the command if the arg is not provided.Steps to Reproduce
/coin check
and pass in no arguments.OR
.coin check
and pass in no arguments.Extra commentary
Not sure if
messageFromUser.member?.user
is the "right" way to get the user, since for some reason accessingmember
can return null from aMessage
?🤷