Skip to content

Fix an issue with alias quote detection#6582

Merged
Flame442 merged 3 commits intoCog-Creators:V3/developfrom
TrustyJAID:fix-alias-quotes
Aug 9, 2025
Merged

Fix an issue with alias quote detection#6582
Flame442 merged 3 commits intoCog-Creators:V3/developfrom
TrustyJAID:fix-alias-quotes

Conversation

@TrustyJAID
Copy link
Copy Markdown
Member

@TrustyJAID TrustyJAID commented Jun 9, 2025

Description of the changes

When an alias is used to invoke a command and the user uses "double quotes" to capture spaces alias would error without responding to the user's input at all. This PR fixes the StringView lookup by stripping whitespace if it encounters it and then a quote character allowing it to pull the quoted text instead.

Have the changes in this PR been tested?

Yes

@github-actions github-actions bot added the Category: Cogs - Alias This is related to the Alias cog. label Jun 9, 2025
@Flame442 Flame442 added the Type: Bug Unexpected behavior, result, or exception. In case of PRs, it is a fix for the foregoing. label Jun 9, 2025
@Flame442 Flame442 self-assigned this Aug 9, 2025
@Flame442 Flame442 added this to the 3.5.21 milestone Aug 9, 2025
Copy link
Copy Markdown
Member

@Flame442 Flame442 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This does not resolve the silent errors described in in #3055 when there are unbalanced quotes, but this does allow balanced quotes to be used in what appears to be an expected way. This seems like a good step for now.

image

@Flame442 Flame442 merged commit b177c80 into Cog-Creators:V3/develop Aug 9, 2025
17 checks passed
@red-githubbot red-githubbot bot added the Changelog Entry: Pending Changelog entry for this PR hasn't been added by repo maintainers yet. label Aug 9, 2025
@Jackenmen Jackenmen added Changelog Entry: Added Changelog entry for this PR has already been added to changelog PR. and removed Changelog Entry: Pending Changelog entry for this PR hasn't been added by repo maintainers yet. labels Aug 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Category: Cogs - Alias This is related to the Alias cog. Changelog Entry: Added Changelog entry for this PR has already been added to changelog PR. Type: Bug Unexpected behavior, result, or exception. In case of PRs, it is a fix for the foregoing.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants