mirror of
https://github.com/ergochat/ergo.git
synced 2025-12-20 02:00:11 -08:00
persist last seen on shutdown
This commit is contained in:
parent
a38d375bda
commit
0f04acaa40
2 changed files with 24 additions and 3 deletions
|
|
@ -116,6 +116,9 @@ func (server *Server) Shutdown() {
|
|||
//TODO(dan): Make sure we disallow new nicks
|
||||
for _, client := range server.clients.AllClients() {
|
||||
client.Notice("Server is shutting down")
|
||||
if client.AlwaysOn() {
|
||||
client.Store(IncludeLastSeen)
|
||||
}
|
||||
}
|
||||
|
||||
if err := server.store.Close(); err != nil {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue