Improve UploadAvatar API.

This commit is contained in:
Yang Luo
2021-04-28 19:02:01 +08:00
parent ee8f2a6046
commit ea9bdbf45e
2 changed files with 16 additions and 11 deletions

View File

@ -1,6 +1,9 @@
package util
import "time"
import (
"strconv"
"time"
)
func GetCurrentTime() string {
timestamp := time.Now().Unix()
@ -8,3 +11,6 @@ func GetCurrentTime() string {
return tm.Format(time.RFC3339)
}
func GetCurrentUnixTime() string {
return strconv.FormatInt(time.Now().UnixNano(), 10)
}