mirror of
https://github.com/astaxie/beego.git
synced 2024-11-22 07:00:55 +00:00
keep the shortname for logs info/warn/debug
This commit is contained in:
parent
d629c1d3d0
commit
0207caab6f
10
log.go
10
log.go
@ -78,9 +78,9 @@ func Warning(v ...interface{}) {
|
||||
BeeLogger.Warning(generateFmtStr(len(v)), v...)
|
||||
}
|
||||
|
||||
// Deprecated: compatibility alias for Warning(), Will be removed in 1.5.0.
|
||||
// compatibility alias for Warning()
|
||||
func Warn(v ...interface{}) {
|
||||
Warning(v...)
|
||||
BeeLogger.Warn(generateFmtStr(len(v)), v...)
|
||||
}
|
||||
|
||||
func Notice(v ...interface{}) {
|
||||
@ -92,9 +92,9 @@ func Informational(v ...interface{}) {
|
||||
BeeLogger.Informational(generateFmtStr(len(v)), v...)
|
||||
}
|
||||
|
||||
// Deprecated: compatibility alias for Warning(), Will be removed in 1.5.0.
|
||||
// compatibility alias for Warning()
|
||||
func Info(v ...interface{}) {
|
||||
Informational(v...)
|
||||
BeeLogger.Info(generateFmtStr(len(v)), v...)
|
||||
}
|
||||
|
||||
// Debug logs a message at debug level.
|
||||
@ -103,7 +103,7 @@ func Debug(v ...interface{}) {
|
||||
}
|
||||
|
||||
// Trace logs a message at trace level.
|
||||
// Deprecated: compatibility alias for Warning(), Will be removed in 1.5.0.
|
||||
// compatibility alias for Warning()
|
||||
func Trace(v ...interface{}) {
|
||||
BeeLogger.Trace(generateFmtStr(len(v)), v...)
|
||||
}
|
||||
|
@ -58,7 +58,7 @@ func serverStaticRouter(ctx *context.Context) {
|
||||
finfo, err := os.Stat(file)
|
||||
if err != nil {
|
||||
if RunMode == "dev" {
|
||||
Warn(err)
|
||||
Warn("Can't find the file:", file, err)
|
||||
}
|
||||
http.NotFound(ctx.ResponseWriter, ctx.Request)
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user