mirror of
https://github.com/ergochat/ergo.git
synced 2024-12-22 18:52:41 +01:00
fix a wide-ranging assortment of crash bugs
This commit is contained in:
parent
ff50a25b65
commit
ca8a0b7091
@ -43,7 +43,10 @@ func (cm *ChannelManager) Get(name string) *Channel {
|
||||
if err == nil {
|
||||
cm.RLock()
|
||||
defer cm.RUnlock()
|
||||
return cm.chans[name].channel
|
||||
entry := cm.chans[name]
|
||||
if entry != nil {
|
||||
return entry.channel
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user