From 3e742a6e142d3e63374db3cad7f6dc95b48b13bc Mon Sep 17 00:00:00 2001
From: zhangmeng <775834166@qq.com>
Date: 星期日, 19 一月 2020 17:09:15 +0800
Subject: [PATCH] if canot find sdk runtime path skip this sdk

---
 app/master/master.go |   20 ++++++++++++--------
 1 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/app/master/master.go b/app/master/master.go
index 4fb75b2..1561d77 100644
--- a/app/master/master.go
+++ b/app/master/master.go
@@ -59,15 +59,19 @@
 			continue
 		}
 
-		envs := strings.Split(cfg.Env, ":")
-		normal := true
-		for _, v := range envs {
-			if !util.IsFileExist(v) {
-				normal = false
+		if len(cfg.Env) > 0 {
+			envs := strings.Split(cfg.Env, ":")
+			normal := true
+			for _, v := range envs {
+				if !util.IsFileExist(v) {
+					normal = false
+					break
+				}
 			}
-		}
-		if !normal {
-			logo.Infoln("Can't Find Runtime Path, Skip It: ", file)
+			if !normal {
+				logo.Infoln("Can't Find Runtime Path, Skip It: ", file)
+				continue
+			}
 		}
 
 		logo.Infoln(file, " CONFIG: ", cfg)

--
Gitblit v1.8.0