Skip to content

Commit

Permalink
Merge pull request #5278 from paulbalandan/pgsql-result
Browse files Browse the repository at this point in the history
Fix compatibility of Postgres result for PHP 8.1
  • Loading branch information
paulbalandan authored Nov 3, 2021
2 parents af247f4 + e94394a commit 4995720
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion system/Database/BaseResult.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ abstract class BaseResult implements ResultInterface
/**
* Result ID
*
* @var bool|object|resource
* @var false|object|resource
*/
public $resultID;

Expand Down
2 changes: 1 addition & 1 deletion system/Database/Postgre/Result.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public function getFieldData(): array
*/
public function freeResult()
{
if (is_resource($this->resultID)) {
if ($this->resultID !== false) {
pg_free_result($this->resultID);
$this->resultID = false;
}
Expand Down

0 comments on commit 4995720

Please sign in to comment.