-
Notifications
You must be signed in to change notification settings - Fork 16
Report Command Implementation - Issue #141 #164
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
Conversation
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.
Pull request overview
This PR implements a /report command allowing players to report others to staff with predefined reasons. The implementation uses interactive menus to select a target player and report reason, then sends the report via the backend API.
Changes:
- Added
setToArrayimport in general.ts - Implemented
/reportcommand with menu-based player and reason selection - Added a humorous comment about "uwu" in the banned words config
Reviewed changes
Copilot reviewed 4 out of 5 changed files in this pull request and generated 22 comments.
Show a summary per file
| File | Description |
|---|---|
| src/config.ts | Added comment questioning the "uwu" ban |
| src/commands/general.ts | Added setToArray import and implemented /report command |
| build/scripts/config.js | Compiled output of config.ts changes |
| build/scripts/commands/general.js | Compiled output of general.ts with report command |
| build/scripts/frameworks/menus.js | Reformatted (no functional changes, just line number updates) |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ).catch(() => { | ||
| outputFail('Report cancelled.'); | ||
| return; | ||
| }); |
Copilot
AI
Jan 12, 2026
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.
The error handling for menu cancellation is inconsistent. When the menu is cancelled via .catch(), the function calls outputFail('Report cancelled.') but then returns undefined, which continues execution. The subsequent if(!target) return; check will properly exit, but the error message is misleading since it suggests the report was cancelled when actually it will proceed if undefined is returned from catch. Consider making the catch handler explicitly return null or use promise rejection to ensure clean control flow.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
why the large diff im shock |
|
Moved to #165 |
based on "#141"
laid the base for report command (idk how to test it from every corner to corner, i tested with what i could using my pc and mobile for two accounts in game).