diff --git a/composer.json b/composer.json index 712b0aa893e8263d0a650e458036c27868e60576..91858d996653cce0ac0adf2ebf9e89929b8ea1ea 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "phptars/tars-client", "description": "tars的php-client能力", - "version":"0.3.0", + "version":"0.3.1", "authors": [ { "name": "Chen Liang", diff --git a/src/Communicator.php b/src/Communicator.php old mode 100644 new mode 100755 index 23fe34a32eb2a76d1f50c4203fb0d885e89eee5a..43d4094fb9eadb83050bff69ada4dbb6bfdaf25b --- a/src/Communicator.php +++ b/src/Communicator.php @@ -66,7 +66,7 @@ class Communicator $this->_queryF = new QueryFWrapper($this->_locator, $this->_routeSocketMode, $this->_refreshEndpointInterval); $this->_routeInfo = $this->_queryF->findObjectById($this->_servantName); // 初始化上报组件,只在指定了主控的前提下 - if(class_exists("\Tars\App")) { + if(class_exists("\Tars\App") && \Tars\App::getStatF()) { $this->_statF = \Tars\App::getStatF(); } else {