1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2026-02-05 15:54:03 +00:00

Clean up isVersion8 code

This commit is contained in:
lukinovec 2023-02-16 16:42:32 +01:00
parent fc370ff789
commit ae472984fa

View file

@ -40,8 +40,8 @@ class PermissionControlledMySQLDatabaseManager extends MySQLDatabaseManager impl
protected function isVersion8(): bool
{
$queryGrammar = $this->database()->getQueryGrammar();
$version = $this->database()->select($this->database()->raw('select version()')->getValue($queryGrammar))[0]->{'version()'};
$versionSelect = $this->database()->raw('select version()')->getValue($this->database()->getQueryGrammar());
$version = $this->database()->select($versionSelect)[0]->{'version()'};
return version_compare($version, '8.0.0') >= 0;
}