diff --git a/client.go b/client.go index 6974a0e..a114bd3 100644 --- a/client.go +++ b/client.go @@ -60,6 +60,7 @@ func setClientBusy(userID64 int64, from time.Time, duration time.Duration) error clt.CWIdle = false clt.CWBusyUntil = from.UTC().Add(duration) clt.Mux.Unlock() + log.Printf("setClientBusy[%s] : set for %s.\n", clt.Login, duration.String()) return nil } else { return errors.New("Client not found.") @@ -69,15 +70,15 @@ func setClientBusy(userID64 int64, from time.Time, duration time.Duration) error } func setClientIdle(userID64 int64, from time.Time) error { - fmt.Printf("setClientIdle : starting for %d.\n", userID64) if clt, ok := getLockedClient(userID64, false); ok { if from.UTC().After(clt.CWLastUpdate.UTC()) { fmt.Printf("setClientIdle : updated.\n") clt.CWBusyUntil = from clt.CWIdle = true clt.CWLastUpdate = from + log.Printf("setClientIdle[%s] : updated.\n", clt.Login) } else { - fmt.Printf("setClientIdle : not updated.\n") + log.Printf("setClientIdle[%s] : not updated.\n", clt.Login) } clt.Mux.Unlock() return nil