diff options
author | hubaishan <saeed@hubaishan.com> | 2018-08-25 16:17:55 +0300 |
---|---|---|
committer | hubaishan <saeed@hubaishan.com> | 2018-08-25 16:17:55 +0300 |
commit | b0b70589a25594a32ad072315e9f78b197e1bea6 (patch) | |
tree | cd4d7a4d17b0c4dd5b7684cc3c791296ad321d4b /phpBB/phpbb/db/driver/mssqlnative.php | |
parent | bd90a5358969e2bb82df34727ed8f6575781e5d2 (diff) | |
download | forums-b0b70589a25594a32ad072315e9f78b197e1bea6.tar forums-b0b70589a25594a32ad072315e9f78b197e1bea6.tar.gz forums-b0b70589a25594a32ad072315e9f78b197e1bea6.tar.bz2 forums-b0b70589a25594a32ad072315e9f78b197e1bea6.tar.xz forums-b0b70589a25594a32ad072315e9f78b197e1bea6.zip |
[ticket/15612] Fix PHP7.2 count() bug in MSSQL driver
sqlsrv_fetch_array() function returns an array when data found,
null when no data or false on error. So we need to change null to false only.
PHPBB3-15612
Diffstat (limited to 'phpBB/phpbb/db/driver/mssqlnative.php')
-rw-r--r-- | phpBB/phpbb/db/driver/mssqlnative.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/phpBB/phpbb/db/driver/mssqlnative.php b/phpBB/phpbb/db/driver/mssqlnative.php index de81a6a0c8..a4dcac5966 100644 --- a/phpBB/phpbb/db/driver/mssqlnative.php +++ b/phpBB/phpbb/db/driver/mssqlnative.php @@ -268,7 +268,7 @@ class mssqlnative extends \phpbb\db\driver\mssql_base unset($row['line2'], $row['line3']); } } - return (count($row)) ? $row : false; + return ($row !== null) ? $row : false; } /** |