mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-07 15:03:09 -06:00
Readability fix
This commit is contained in:
parent
5100c564c2
commit
b7c42f7a52
|
|
@ -80,7 +80,10 @@ func (s *Statistics) ForServer(serverName spec.ServerName) *ServerStatistics {
|
||||||
|
|
||||||
// Don't bother hitting the database 2 additional times
|
// Don't bother hitting the database 2 additional times
|
||||||
// if we don't want to use relays.
|
// if we don't want to use relays.
|
||||||
if s.enableRelays {
|
if !s.enableRelays {
|
||||||
|
return server
|
||||||
|
}
|
||||||
|
|
||||||
assumedOffline, err := s.DB.IsServerAssumedOffline(context.Background(), serverName)
|
assumedOffline, err := s.DB.IsServerAssumedOffline(context.Background(), serverName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logrus.WithError(err).Errorf("Failed to get assumed offline entry %q", serverName)
|
logrus.WithError(err).Errorf("Failed to get assumed offline entry %q", serverName)
|
||||||
|
|
@ -97,7 +100,6 @@ func (s *Statistics) ForServer(serverName spec.ServerName) *ServerStatistics {
|
||||||
server.relayMutex.Unlock()
|
server.relayMutex.Unlock()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
return server
|
return server
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue