From f1cc112a52198c30ab5b213116b4daf027af1fe8 Mon Sep 17 00:00:00 2001 From: Liang Ding Date: Thu, 16 May 2019 12:07:21 +0800 Subject: [PATCH] =?UTF-8?q?:art:=20=E8=AF=BB=E5=8F=96=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E7=9B=AE=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- conf/wide.go | 3 +-- main.go | 3 --- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/conf/wide.go b/conf/wide.go index 6a5b67b..4503c25 100644 --- a/conf/wide.go +++ b/conf/wide.go @@ -125,8 +125,7 @@ func initUsers(confUsers string) { user := &User{} - bytes, _ := ioutil.ReadFile("conf/users/" + name) - + bytes, _ := ioutil.ReadFile(filepath.Join(confUsers, name)) err := json.Unmarshal(bytes, user) if err != nil { logger.Errorf("Parses [%s] error: %v, skip loading this user", name, err) diff --git a/main.go b/main.go index dc0ff02..3a5ac61 100644 --- a/main.go +++ b/main.go @@ -66,9 +66,6 @@ func init() { log.SetLevel("warn") logger = log.NewLogger(os.Stdout) - logger.Warn(*confUsers) - logger.Warn(*confUsersWorkspaces) - //wd := util.OS.Pwd() //if strings.HasPrefix(wd, os.TempDir()) { // logger.Error("Don't run Wide in OS' temp directory or with `go run`")