5
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2024-12-24 17:15:40 +00:00

Add extra debug to log time spent sending a message per bridge (#1299)

This commit is contained in:
Wim 2020-11-22 17:20:20 +01:00 committed by GitHub
parent c23252ab53
commit eff41759bc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -477,6 +477,10 @@ func (gw *Gateway) SendMessage(
gw.Router.MattermostPlugin <- msg
}
defer func(t time.Time) {
gw.logger.Debugf("=> Send from %s (%s) to %s (%s) took %s", msg.Account, rmsg.Channel, dest.Account, channel.Name, time.Since(t))
}(time.Now())
mID, err := dest.Send(msg)
if err != nil {
return mID, err