Browse Source

Add default behave of logger

Unknown 11 years ago
parent
commit
003298ef1d
1 changed files with 5 additions and 0 deletions
  1. 5 0
      modules/log/log.go

+ 5 - 0
modules/log/log.go

@@ -11,6 +11,11 @@ import (
 
 var logger *logs.BeeLogger
 
+func init() {
+	logger = logs.NewLogger(10000)
+	logger.SetLogger("console", `{"level": 0}`)
+}
+
 func NewLogger(bufLen int64, mode, config string) {
 	logger = logs.NewLogger(bufLen)
 	logger.SetLogger(mode, config)