Skip to content

Commit

Permalink
Fix "key required" crash when channel ID can't be found (#496)
Browse files Browse the repository at this point in the history
  • Loading branch information
hloeung authored Nov 7, 2022
1 parent bd7bfba commit 3bd2ba8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mm-go-irckit/userbridge.go
Original file line number Diff line number Diff line change
Expand Up @@ -1198,6 +1198,10 @@ func (u *User) loadLastViewedAt() map[string]int64 {
}

func (u *User) saveLastViewedAt(channelID string) {
if channelID == "" {
return
}

currentTime := make([]byte, 8)
binary.LittleEndian.PutUint64(currentTime, uint64(model.GetMillis()))

Expand Down

0 comments on commit 3bd2ba8

Please sign in to comment.