| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
Matrix quotes replies and as of matterbridge 1.24.0 we strip those as this causes
issues with bridges support threading and have PreserveThreading enabled.
Introduced via https://github.com/42wim/matterbridge/commit/9a8ce9b17e560433731eb5efa3cee7ced0b93605
But if you for example use mattermost or discord with webhooks you'll need to enable
this if you want something that looks like a reply from matrix.
See issues:
- https://github.com/42wim/matterbridge/issues/1819
- https://github.com/42wim/matterbridge/issues/1780
|
|
|
|
|
|
|
|
| |
Sorta regression introduced by 9a8ce9b17e560433731eb5efa3cee7ced0b93605
which changes the way we get replies of matrix.
This causes issues like https://github.com/42wim/matterbridge/issues/1780
We "fix" this by mimicking the old behaviour when "PreserveThreading" is
disabled.
|
|
|
|
|
| |
* Switch to upstream discordgo again
* Fix discord api changes
|
|
|
|
|
| |
debuglevel=1 dumps every received discord event
debuglevel=2 dumps every discord event we are sending to discord (also
logs sensitive information)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We create a new event EventFileDelete which will be used to delete
specific uploaded files using the Extra["file"] in the config.Message.
We also add a new NativeID key to the FileInfo struct which will contain
the native file ID of the sending bridge.
When a new file is added to the config.Message.Extra["file"] map, now
the bridge native file ID should be added here.
When the receiving bridge receives such a message, it should keep an
internal mapping of NativeID <> bridge fileid/message id. In the case of
discord we map it to the resulted discord message ID after uploading it.
Now when a bridge deletes a file, it should send a EventFileDelete and
setting the ID to the native file ID of the bridge.
When the receiving bridge will get this event it'll look into the
NativeID <> bridge id mapping to find their internal ID and use it to
delete the specific file on their side.
For now this is implemented for slack to discord but this will be add to
other bridges where useful.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add's comments to message in telegram messages
This is a change to handle comments in telegram messages!
Some messages in telegram have comments added to the message! This normally is the description in images or links. This changes appends the comment to the message if available.
This should fix the issue in #1649
* [fix] discord: send comments in extras
Co-authored-by: Wim <wim@42.be>
|
|
|
|
| |
(#1487)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add DisablePingEveryoneHere/DisablePingRoles/DisablePingUsers keys to config
* Add basic AllowedMentions behavior to discord webhooks
* Initialize b.AllowedMentions on Discord Bridger init
* Call b.getAllowedMentions on each webhook to allow config hot reloading
* Add AllowedMentions on all Discord webhooks/messages
* Add DisablePingEveryoneHere/DisablePingRoles/DisablePingUsers to matterbridge.toml.sample
* Change 'Disable' for 'Allow' and revert logic in Discord AllowedMentions
* Update Discord AllowedMentions in matterbridge.toml.sample
* Fix typo in DisableWebPagePreview
* Replace 'AllowPingEveryoneHere' with 'AllowPingEveryone'
* Replace 3 AllowPingEveryone/Roles/Users bools with an array
* Fix typo
|
|
|
|
|
|
|
|
| |
Without this declared, it seems that Discord will not send any member update
events after connection, even if the privileged gateway intent is enabled for
the bot in settings. This causes nick tracking to get out of sync when people
change their nicks after the bot connects.
See: https://discord.com/developers/docs/topics/gateway#gateway-intents
|
|
|
|
|
|
| |
* Use valid transmitter Log default (discord)
Using a logger created by `log.NewEntry(nil)` would crash. (matterbridge does not encounter this issue as it updates the Log field manually.)
|
| |
|
|
|
| |
Enable discordgo debugging with debuglevel=1 under the [discord.xxx] section, for even more debugging fun.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Discord message references have been designed in a way for this to
support cross-channel or even cross-guild references in the future.
This will ensure the ParentID is *not* set when the message refers to a
message that was sent in a different channel.
|
| |
|
|
|
|
|
|
|
|
| |
Webhooks don't support the threading yet, so this is token only.
In discord you can reply on each message of a thread, but this is not possible in mattermost (so some changes added there to make sure we always answer on the rootID of the thread).
Also needs some more testing with slack.
update : It now also uses the token when replying to a thread (even if webhooks are enabled), until webhooks have support for threads.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
This has been tested with one webhook in one channel.
Sends, edits and deletions work fine
|
|
|
|
| |
This reverts commit c23252ab53182cc6e68086f29c7137fbc27917ee.
|
| |
|
|
|
|
|
|
|
| |
See https://github.com/42wim/matterbridge/issues/1255 and
https://github.com/qaisjp/go-discord-irc/issues/57
Webhook edits gets ratelimited which cause other problems with
matterbridge. Disabling for now.
|
|
|
|
|
|
|
|
|
|
|
|
| |
When using the webhook, the previous method to edit a message was to
delete the old one via the classical API, and to create a new message
via the webhook. While this works, this means that editing "old" messages
lead to a mess where the chronological order is no longer respected.
This uses an hidden API explained in https://support.discord.com/hc/en-us/community/posts/360034557771
to achieve a proper edition using the webhook API.
The obvious downside of this approach is that since it is an
undocumented API for now, so there is no stability guarantee :/
|
|
|
| |
Fixes #1132
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
When a webhook "edits" a message, it does this by deleting the message
and creating a new one with the new content.
On creation of this new message, we'll get another ID then already is
know by the gateway in its id cache. So we add it in our own cache and
replace it whenever we want to edit/delete it again.
|
| |
|
| |
|
|
|
|
| |
Make this work for all possible cases.
Add tests
|
| |
|
| |
|
| |
|
|
|
|
| |
See https://github.com/golang/go/issues/30354
go get doesn't honor the go.mod replace options.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* remote_avatar: add UseLocalAvatar
* remote_avatar: make sure msg.Protocol is always set correctly
* remote_avatars: support msg.Account
* remote_avatar: add to matterbridge.toml.sample
* remote_avatar: clarify something
|
|
|
|
|
|
| |
* Check only bridged channels for PermManageWebhooks
* add note
|
|
|
|
| |
#962 (#995)
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* move stripCustomoji logic to default Tengo script
Removing the image ID from the message (without any possibility of recovering it later) is a loss of valuable data that prevents users from giving support to custom emoji via Tengo scripts.
* bugfix - do send colors to other irc bridges
"if we're not sending to an irc bridge we strip the IRC colors"
Co-authored-by: c0ncord <59654954+c0ncord@users.noreply.github.com>
|
|
|
|
|
|
| |
* Update vendor
* Fix godiscord api change
|
|
|
|
| |
Since v1.16.0 we now can upload files via webhook.
Old way of showing files with webhook only setup can be removed.
|
|
|
|
|
|
|
|
| |
* Add Discord to UserTypingSupport
* discord: start typing in a channel on EventUserTyping receive
* discord: emit EventUserTyping to gateway
|
| |
|
| |
|
| |
|