diff --git a/server/analyseapi/riskmgr.go b/server/analyseapi/riskmgr.go index f35023a..45f9316 100644 --- a/server/analyseapi/riskmgr.go +++ b/server/analyseapi/riskmgr.go @@ -298,6 +298,9 @@ func (this *RiskMgr) __analyseIsOpen(w* http.ResponseWriter, r *http.Request) { atomic.AddInt64(&this.totalPassTimes, 1) atomic.AddInt64(&this.passTimes, 1) if this.clusterConf.GetTesting() == 1 { + if response_str == "" { + response_str = `""` + } data := fmt.Sprintf(`{"errcode":0, "errmsg":"", "is_open":%d, "data":%s}`, 1, response_str) @@ -309,6 +312,9 @@ func (this *RiskMgr) __analyseIsOpen(w* http.ResponseWriter, r *http.Request) { atomic.AddInt64(&this.totalBlockTimes, 1) atomic.AddInt64(&this.blockTimes, 1) if this.clusterConf.GetTesting() == 1 { + if response_str == "" { + response_str = `""` + } data := fmt.Sprintf(`{"errcode":0, "errmsg":"", "is_open":%d, "data":%s}`, 0, response_str)