Merge pull request #5765 from oiooj/master

No need check Meta.Dir twice
pull/5803/merge
Jason Wilder 2016-02-23 11:20:24 -07:00
commit e0b23fd5b0
1 changed files with 0 additions and 5 deletions

View File

@ -125,11 +125,6 @@ func NewServer(c *Config, buildInfo *BuildInfo) (*Server, error) {
}
}
// Create the root directory if it doesn't already exist.
if err := os.MkdirAll(c.Meta.Dir, 0777); err != nil {
return nil, fmt.Errorf("mkdir all: %s", err)
}
// 0.11 we no longer use peers.json. Remove the file if we have one on disk.
os.RemoveAll(filepath.Join(c.Meta.Dir, "peers.json"))