From 4457c035d30e58ef0f5e1ff02d5265da0ff498a5 Mon Sep 17 00:00:00 2001 From: thinkphp Date: Sat, 4 Mar 2023 22:23:47 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9Bpgsql=E9=A9=B1=E5=8A=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/db/connector/Pgsql.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/db/connector/Pgsql.php b/src/db/connector/Pgsql.php index 3779c965..023a886f 100644 --- a/src/db/connector/Pgsql.php +++ b/src/db/connector/Pgsql.php @@ -75,7 +75,7 @@ public function getFields(string $tableName): array 'notnull' => (bool) ('' !== $val['null']), 'default' => $val['default'], 'primary' => !empty($val['key']), - 'autoinc' => str_starts_with($val['extra'], 'nextval('), + 'autoinc' => str_starts_with((string) $val['extra'], 'nextval('), ]; } }