From e0f46fc691aaa0e346cec127833cf6db68d5823c Mon Sep 17 00:00:00 2001 From: F4nniu Date: Sun, 3 Apr 2022 19:05:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20implode=20=E5=87=BD?= =?UTF-8?q?=E6=95=B0=E4=BD=BF=E7=94=A8=EF=BC=8C=E8=B0=83=E6=8D=A2=E5=8F=82?= =?UTF-8?q?=E6=95=B0=EF=BC=8C=E6=97=A7=E7=9A=84=E6=96=B9=E5=BC=8F=E5=9C=A8?= =?UTF-8?q?=207.4=20=E5=90=8E=E5=B0=86=E5=BA=9F=E9=99=A4=EF=BC=8C=E6=84=9F?= =?UTF-8?q?=E8=B0=A2=20@chinayin=20=E7=9A=84=E5=8F=8D=E9=A6=88=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/db/Builder.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/think/db/Builder.php b/library/think/db/Builder.php index 77bb9794..16480d38 100644 --- a/library/think/db/Builder.php +++ b/library/think/db/Builder.php @@ -386,7 +386,7 @@ abstract class Builder $array[] = $key . ' ' . $exp . ' ' . $this->parseValue($item, $field); } $logic = isset($val[2]) ? $val[2] : 'AND'; - $whereStr .= '(' . implode($array, ' ' . strtoupper($logic) . ' ') . ')'; + $whereStr .= '(' . implode(' ' . strtoupper($logic) . ' ', $array) . ')'; } else { $whereStr .= $key . ' ' . $exp . ' ' . $this->parseValue($value, $field); }