Skip to content

Commit 3eb8740

Browse files
committed
AC-7469: Add support for MySQL8.0.29 and higher
1 parent 4cd541e commit 3eb8740

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lib/internal/Magento/Framework/DB/Adapter/SqlVersionProvider.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
namespace Magento\Framework\DB\Adapter;
99

1010
use Magento\Framework\App\ResourceConnection;
11+
use Magento\Tests\NamingConvention\true\bool;
1112

1213
/**
1314
* Class GetDbVersion provides sql engine version requesting version variable
@@ -126,15 +127,15 @@ private function fetchSqlVersion(string $resource): string
126127
/**
127128
* Check if MySQL version is greater than equal to 8.0.29
128129
*
129-
* @return void
130+
* @return bool
130131
* @throws ConnectionException
131132
*/
132-
public function isMysqlGte8029()
133+
public function isMysqlGte8029(): bool
133134
{
134135
$sqlVersion = $this->getSqlVersion();
135136
$isMariaDB = str_contains($sqlVersion, SqlVersionProvider::MARIA_DB_10_VERSION);
136137
$sqlExactVersion = $this->fetchSqlVersion(ResourceConnection::DEFAULT_CONNECTION);
137-
if (!$isMariaDB && version_compare($sqlExactVersion, "8.0.29", ">=")) {
138+
if (!$isMariaDB && version_compare($sqlExactVersion, '8.0.29', '>=')) {
138139
return true;
139140
}
140141
return false;

0 commit comments

Comments
 (0)