1
0
Fork 0
forked from goffee/cup

sample users admin

This commit is contained in:
Zeni Kim 2024-12-04 08:39:08 -05:00
parent 19c24593fe
commit 0f520e67af
9 changed files with 488 additions and 3 deletions

View file

@ -8,6 +8,7 @@ package utils
import (
"crypto/md5"
"fmt"
"time"
)
// generate a hashed string to be used as key for caching auth jwt token
@ -17,3 +18,7 @@ func CreateAuthTokenHashedCacheKey(userID uint, userAgent string) string {
return hashedCacheKey
}
func FormatUnix(value int64) string {
return time.Unix(value, 0).Format("2006-01-02 15:04:05")
}