From c60d8d2dc922e41725e9c484c7cca5263ad4cbc5 Mon Sep 17 00:00:00 2001 From: JaguarJack Date: Tue, 26 May 2020 09:32:52 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- extend/catcher/CatchQuery.php | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/extend/catcher/CatchQuery.php b/extend/catcher/CatchQuery.php index 95d2e21..cad39d2 100644 --- a/extend/catcher/CatchQuery.php +++ b/extend/catcher/CatchQuery.php @@ -101,14 +101,15 @@ class CatchQuery extends Query return $this; } - /** - * - * @time 2020年01月13日 - * @return CatchQuery - */ - public function catchSearch(): CatchQuery + /** + * + * @time 2020年01月13日 + * @param array $params + * @return CatchQuery + */ + public function catchSearch($params = []): CatchQuery { - $params = \request()->param(); + $params = empty($params) ? \request()->param() : $params; if (empty($params)) { return $this;