Skip to content

Commit f5dfc60

Browse files
authored
Merge pull request #7 from phpugph/1.0
cleaner php9 update
2 parents b74ae1c + 9c0f969 commit f5dfc60

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

composer.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@
1010
],
1111
"license": "MIT",
1212
"require-dev": {
13+
"php-coveralls/php-coveralls": "2.5.2",
1314
"phpunit/phpunit": "9.5.21",
14-
"squizlabs/php_codesniffer": "3.7.1",
15-
"php-coveralls/php-coveralls": "2.5.2"
15+
"squizlabs/php_codesniffer": "3.7.1"
1616
},
1717
"require": {
18-
"phpugph/components": "1.0.5"
18+
"phpugph/components": "1.0.6"
1919
},
2020
"autoload": {
2121
"psr-4": {

src/Engine/PostGreSql.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -189,9 +189,9 @@ public function getColumns(string $table, ?string $schema = null): array
189189
$columns = [];
190190
foreach ($results as $column) {
191191
$key = null;
192-
if (strpos((string) $column['index_type'], '_pkey') !== false) {
192+
if (strpos($column['index_type'] ?? '', '_pkey') !== false) {
193193
$key = 'PRI';
194-
} else if (strpos((string) $column['index_type'], '_key') !== false) {
194+
} else if (strpos($column['index_type'] ?? '', '_key') !== false) {
195195
$key = 'UNI';
196196
}
197197

0 commit comments

Comments
 (0)