Skip to content
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

Checking message parts throws StringIndexOutOfBoundsException #60

Open
3 tasks done
Matyrobbrt opened this issue Apr 7, 2022 · 0 comments · May be fixed by #61
Open
3 tasks done

Checking message parts throws StringIndexOutOfBoundsException #60

Matyrobbrt opened this issue Apr 7, 2022 · 0 comments · May be fixed by #61
Labels
bug Something isn't working module: command Commands module

Comments

@Matyrobbrt
Copy link

Issue Checklist

  • I have checked for similar issues on the Issue tracker
  • I have updated to the latest version of JDA-Chewtils.
  • I have checked the branches or the maintainer's PRs for upcoming bug fixes.

Affected Modules

Command

Description

Currently, CommandClientImpl#getParts always expects a space after the mention:

On top of that we need to do another +1 because the default @mention prefix will always be followed by a space

However, this causes a StringIndexOutOfBoundsException when a message is just a ping without a space (for example, if the bot is pinged to make it join a thread).

@Matyrobbrt Matyrobbrt linked a pull request Apr 7, 2022 that will close this issue
5 tasks
@Chew Chew added bug Something isn't working module: command Commands module labels Apr 7, 2022
@Chew Chew mentioned this issue Aug 20, 2022
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working module: command Commands module
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants