Skip to content

Commit

Permalink
Update JetBrains PhpStorm stubs to 2022.1
Browse files Browse the repository at this point in the history
  • Loading branch information
morozov committed Apr 14, 2022
1 parent 719663b commit f41f3c1
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 15 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
},
"require-dev": {
"doctrine/coding-standard": "9.0.0",
"jetbrains/phpstorm-stubs": "2021.1",
"jetbrains/phpstorm-stubs": "2022.1",
"phpstan/phpstan": "1.5.3",
"phpstan/phpstan-strict-rules": "^1.1",
"phpunit/phpunit": "9.5.16",
Expand Down
6 changes: 6 additions & 0 deletions phpstan.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,12 @@ parameters:
paths:
- src/Driver/OCI8/Statement.php

# https://github.com/phpstan/phpstan-src/pull/1214
-
message: '~^Expression on left side of \?\? is not nullable\.$~'
paths:
- src/Driver/IBMDB2/Connection.php

# TODO: check for null after calling Connection::getDatabase()
-
message: '~Parameter.*\$database of method.*expects string, string\|null given\.~'
Expand Down
13 changes: 0 additions & 13 deletions psalm.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -253,10 +253,6 @@
</DeprecatedProperty>
<DocblockTypeContradiction>
<errorLevel type="suppress">
<!--
Requires a release of https://github.com/JetBrains/phpstorm-stubs/pull/766
-->
<file name="src/Driver/Mysqli/Result.php"/>
<!--
These issues can be mostly divided in the following categories:
1. Union types not supported at the language level (require dropping PHP 7 support)
Expand Down Expand Up @@ -439,15 +435,6 @@
<file name="tests/Platforms/AbstractMySQLPlatformTestCase.php"/>
</errorLevel>
</TooManyArguments>
<UndefinedConstant>
<errorLevel type="suppress">
<!--
Requires a release of
https://github.com/JetBrains/phpstorm-stubs/pull/732
-->
<file name="tests/Driver/PDO/PgSQL/DriverTest.php" />
</errorLevel>
</UndefinedConstant>
<UndefinedDocblockClass>
<errorLevel type="suppress">
<!-- See https://github.com/vimeo/psalm/issues/5472 -->
Expand Down
2 changes: 1 addition & 1 deletion src/Driver/IBMDB2/Connection.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public function lastInsertId($name = null)
);
}

return db2_last_insert_id($this->connection);
return db2_last_insert_id($this->connection) ?? false;
}

public function beginTransaction(): bool
Expand Down

0 comments on commit f41f3c1

Please sign in to comment.