From d29020f06595dfe7a395199fea65e2f00db277cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=91=E6=9E=97?= Date: Thu, 28 Oct 2021 17:34:10 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/JsonRpcConsumers.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/JsonRpcConsumers.php b/src/JsonRpcConsumers.php index 1140bd8..860fd02 100644 --- a/src/JsonRpcConsumers.php +++ b/src/JsonRpcConsumers.php @@ -96,9 +96,13 @@ abstract class JsonRpcConsumers implements OnRpcConsumerInterface /** * @param $service * @return array + * @throws Exception */ private function get_consul($service): array { + if (empty($service)) { + throw new Exception('You need set rpc service name if used.'); + } // $sf = Kiri::getDi()->get(Catalog::class); // // $content = $sf->service($service)->getBody()->getContents();