Browse Source

allow default logger

master v0.1.4
ldf 3 years ago
parent
commit
66ee74ffbe
  1. 8
      logger.go

8
logger.go

@ -41,8 +41,14 @@ func init() {
)
log.Println("config file name -->", ConfigFile)
log.Println("starting ...")
if _, err := toml.DecodeFile(ConfigFile, &logCfg); err != nil {
log.Fatalf("Read config file err:%s", err.Error())
//log.Fatalf("Read config file err:%s", err.Error())
log.Println("failed to open config file")
if err = InitLog(""); nil != err {
log.Println(err.Error())
}
return
}
cfg = logCfg.Logs

Loading…
Cancel
Save