diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..38c5925 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ + +pokerogue-server.exe diff --git a/db/account.go b/db/account.go index 534e814..bd0abd8 100644 --- a/db/account.go +++ b/db/account.go @@ -21,6 +21,11 @@ func AddAccountSession(username string, token []byte) error { return err } + _, err = handle.Exec("UPDATE accounts SET lastLoggedIn = UTC_TIMESTAMP() WHERE username = ?", username) + if err != nil { + return err + } + return nil }