diff options
author | Wim <wim@42.be> | 2018-04-29 15:46:40 +0200 |
---|---|---|
committer | Wim <wim@42.be> | 2018-04-29 15:46:40 +0200 |
commit | cd1fd1bb7c926f5f78334d08ade7e395cac87247 (patch) | |
tree | 5e65240240e5b1fd844639e215f88ba0f8ce7591 /bridge/telegram/telegram.go | |
parent | d44df7b6e66e6ba9b73c615401ddb83d8f827c50 (diff) | |
download | matterbridge-msglm-cd1fd1bb7c926f5f78334d08ade7e395cac87247.tar.gz matterbridge-msglm-cd1fd1bb7c926f5f78334d08ade7e395cac87247.tar.bz2 matterbridge-msglm-cd1fd1bb7c926f5f78334d08ade7e395cac87247.zip |
Fix panic (telegram). Closes #410
Diffstat (limited to 'bridge/telegram/telegram.go')
-rw-r--r-- | bridge/telegram/telegram.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bridge/telegram/telegram.go b/bridge/telegram/telegram.go index ee7309ed..93ccb2f4 100644 --- a/bridge/telegram/telegram.go +++ b/bridge/telegram/telegram.go @@ -154,11 +154,11 @@ func (b *Btelegram) handleRecv(updates <-chan tgbotapi.Update) { // set the ID's from the channel or group message rmsg.ID = strconv.Itoa(message.MessageID) - rmsg.UserID = strconv.Itoa(message.From.ID) rmsg.Channel = strconv.FormatInt(message.Chat.ID, 10) // handle username if message.From != nil { + rmsg.UserID = strconv.Itoa(message.From.ID) if b.GetBool("UseFirstName") { rmsg.Username = message.From.FirstName } |