4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-07-05 18:24:03 +00:00

Update vendor

* go-telegram-bot-api/telegram-bot-api
* lrstanley/girc
* matterbridge/gomatrix
This commit is contained in:
Wim
2019-01-03 00:07:50 +01:00
parent c585d00f16
commit d2044c647b
18 changed files with 310 additions and 72 deletions

View File

@ -419,14 +419,16 @@ func (s *state) lookupUser(name string) *User {
}
// createUser creates the user in state, if not already done.
func (s *state) createUser(nick string) (ok bool) {
if _, ok := s.users[ToRFC1459(nick)]; ok {
func (s *state) createUser(src *Source) (ok bool) {
if _, ok := s.users[src.ID()]; ok {
// User already exists.
return false
}
s.users[ToRFC1459(nick)] = &User{
Nick: nick,
s.users[src.ID()] = &User{
Nick: src.Name,
Host: src.Host,
Ident: src.Ident,
FirstSeen: time.Now(),
LastActive: time.Now(),
Perms: &UserPerms{channels: make(map[string]Perms)},