Commit 4f819dbd authored by asta.xie's avatar asta.xie

Add a function SetLogFuncCall to enable

parent 3f5fee2d
......@@ -60,7 +60,6 @@ var (
AdminHttpPort int
FlashName string // name of the flash variable found in response header and cookie
FlashSeperator string // used to seperate flash key:value
EnableLogFuncCallDepth bool // enable the funcCallDeppth
)
func init() {
......@@ -134,10 +133,6 @@ func init() {
// init BeeLogger
BeeLogger = logs.NewLogger(10000)
BeeLogger.SetLogger("console", "")
if EnableLogFuncCallDepth {
BeeLogger.EnableFuncCallDepth(true)
BeeLogger.SetLogFuncCallDepth(3)
}
err := ParseConfig()
if err != nil && !os.IsNotExist(err) {
......
......@@ -22,6 +22,11 @@ func SetLevel(l int) {
BeeLogger.SetLevel(l)
}
func SetLogFuncCall(b bool) {
BeeLogger.EnableFuncCallDepth(b)
BeeLogger.SetLogFuncCallDepth(3)
}
// logger references the used application logger.
var BeeLogger *logs.BeeLogger
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment