forked from External/ergo
fix some issues found with staticcheck.io
This commit is contained in:
parent
ce6a3e42df
commit
c193def606
9 changed files with 12 additions and 63 deletions
|
|
@ -52,7 +52,7 @@ func (m *SnoManager) RemoveMasks(client *Client, masks ...sno.Mask) {
|
|||
for _, mask := range masks {
|
||||
currentClientList := m.sendLists[mask]
|
||||
|
||||
if currentClientList == nil || len(currentClientList) == 0 {
|
||||
if len(currentClientList) == 0 {
|
||||
continue
|
||||
}
|
||||
|
||||
|
|
@ -70,7 +70,7 @@ func (m *SnoManager) RemoveClient(client *Client) {
|
|||
for mask := range m.sendLists {
|
||||
currentClientList := m.sendLists[mask]
|
||||
|
||||
if currentClientList == nil || len(currentClientList) == 0 {
|
||||
if len(currentClientList) == 0 {
|
||||
continue
|
||||
}
|
||||
|
||||
|
|
@ -87,7 +87,7 @@ func (m *SnoManager) Send(mask sno.Mask, content string) {
|
|||
|
||||
currentClientList := m.sendLists[mask]
|
||||
|
||||
if currentClientList == nil || len(currentClientList) == 0 {
|
||||
if len(currentClientList) == 0 {
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue