Skip to content
Snippets Groups Projects
Commit bf357f34 authored by cvictory's avatar cvictory
Browse files

forbid excuting twice

parent 457da8fc
No related branches found
No related tags found
No related merge requests found
......@@ -60,6 +60,10 @@ type Logger interface {
}
func init() {
// forbidden to executing twice.
if logger != nil {
return
}
logConfFile := os.Getenv(constant.APP_LOG_CONF_FILE)
err := InitLog(logConfFile)
if err != nil {
......
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