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

Fix /me not going through upon sending an identical message #3166

Merged
merged 4 commits into from Aug 15, 2021

Conversation

zneix
Copy link
Collaborator

@zneix zneix commented Aug 14, 2021

Pull request checklist:

  • CHANGELOG.md was updated, if applicable

Description

Whenever a message starts with / or . we need to ignore first space as it is not treated as the message content by Twitch. Be it either a command starting with these characters or an escaped message, like . .foo bar.

Look at the examples below (for better visibility, spaces were replaced with underscores)
"Goes through" is based on whether sending 2 identical messages in a row through Chatterino works or not.

Message Message content
(as interpreted by Twitch)
Goes through on master? Goes through on PR?
foo foo ✔️ ✔️
foo_bar foo_bar ✔️ ✔️
.foo_bar bar ✔️
.foo__bar bar ✔️
.foo_bar_baz bar_baz ✔️
.foo_bar__baz bar__baz ✔️
._foo foo ✔️
._.foo .foo ✔️
._foo_bar foo_bar ✔️
._foo__bar foo__bar ✔️
.__foo_bar foo_bar ✔️
.__foo__bar foo__bar ✔️

Fixes #3141

@zneix zneix requested a review from Mm2PL August 14, 2021 17:00
@pajlada pajlada merged commit 9a1e405 into master Aug 15, 2021
@pajlada pajlada deleted the zneix/fix/double-spaces-in-commands branch August 15, 2021 09:52
zneix added a commit to SevenTV/chatterino7 that referenced this pull request Aug 15, 2021
Now we're on commit 1d664f8; Changes from upstream we've pulled:

- Minor: Allow resub messages to show in `/mentions` tab (Chatterino#3148)
- Minor: Added a setting to hide similar messages by any user. (Chatterino#2716)
- Minor: Duplicate spaces now count towards the display message length. (Chatterino#3002)
- Minor: Commands are now backed up. (Chatterino#3168)
- Bugfix: Restored ability to send duplicate `/me` messages. (Chatterino#3166)
- Bugfix: Notifications for moderators about other moderators deleting messages can now be disabled. (Chatterino#3121)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Impossible to post the same /me message twice in a row with new double-space workaround
3 participants