mirror of
https://github.com/halejohn/Cloudreve.git
synced 2026-01-26 09:34:57 +08:00
Feat: insert file record to database
This commit is contained in:
@@ -35,8 +35,11 @@ var colors = map[string]func(a ...interface{}) string{
|
||||
|
||||
// Println 打印
|
||||
func (ll *Logger) Println(prefix string, msg string) {
|
||||
// TODO Release时去掉
|
||||
color.NoColor = false
|
||||
|
||||
c := color.New()
|
||||
_, _ = c.Printf("%s %s %s\n", colors[prefix]("["+prefix+"]"), time.Now().Format("2006-01-02 15:04:05 -0700"), msg)
|
||||
_, _ = c.Printf("%s %s %s\n", colors[prefix]("["+prefix+"]"), time.Now().Format("2006-01-02 15:04:05"), msg)
|
||||
}
|
||||
|
||||
// Panic 极端错误
|
||||
|
||||
Reference in New Issue
Block a user