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

Defer to discord for disabling at-everyone in webhooks #497

Merged
merged 1 commit into from
Aug 4, 2019

Conversation

Throne3d
Copy link
Collaborator

@Throne3d Throne3d commented Aug 1, 2019

Currently, webhooks permit IRC users to send @everyone and @here pings through, as they're not stripped (and webhooks always have this permission).

Discord already has permissions for whether the bot can ping everyone, and the webhook send method has a disableEveryone option, so let's defer to the inbuilt Discord permission for this.

When permissions can't be found (shouldn't happen), defaults to disabling the pings.

Fixes #494. Supersedes #496 and #457.

Discord already has permissions for whether the bot can ping everyone,
and the webhook send method has a `disableEveryone` option, so let's
defer to the inbuilt Discord permission for this.

When permissions can't be found (shouldn't happen), defaults to
disabling the pings.

Fixes reactiflux#494
@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 81.25% when pulling f6d0910 on Throne3d:fix/494-webhooks-at-everyone into ef553d3 on reactiflux:master.

1 similar comment
@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 81.25% when pulling f6d0910 on Throne3d:fix/494-webhooks-at-everyone into ef553d3 on reactiflux:master.

@Tsunder
Copy link

Tsunder commented Aug 2, 2019

This appears to, when a user with a name partially matching here / everyone, for example "eve" exists in the server, will ping "eve" instead of everyone.

though, this lax pinging seems to be greater than the scope of this issue. /o/

@Throne3d
Copy link
Collaborator Author

Throne3d commented Aug 2, 2019

That's standard for Discord pings – if you type @Throne3dtest, and there's a user @Throne3d on your server, it'll ping them with "test" appended (no space). I think it's fine for the behavior to stay like this, because of that.

@Throne3d
Copy link
Collaborator Author

Throne3d commented Aug 4, 2019

I'll merge this for now, since it seems quite important for large bridges – we can amend it later if needs be.

@Throne3d Throne3d merged commit 3b362d8 into reactiflux:master Aug 4, 2019
@Throne3d Throne3d deleted the fix/494-webhooks-at-everyone branch August 4, 2019 21:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

IRC users can ping @everyone
3 participants