+ if c.FileConf.LogsDir != "" && !common.Exists(c.FileConf.LogsDir) {
+ if err := os.MkdirAll(c.FileConf.LogsDir, 0770); err != nil {
+ return nil, fmt.Errorf("Cannot create logs dir: %v", err)
+ }
+ }
+ c.Log.Infoln("Logs directory: ", c.FileConf.LogsDir)
+
+ return &c, nil