mirror of
https://github.com/nextcloud/server.git
synced 2026-02-18 18:28:50 -05:00
fix: only compare major version of pgsql
Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
This commit is contained in:
parent
3ce8c6d0db
commit
2e94ec8832
1 changed files with 3 additions and 0 deletions
|
|
@ -80,6 +80,9 @@ class SupportedDatabase implements ISetupCheck {
|
|||
$row = $result->fetch();
|
||||
$version = $row['server_version'];
|
||||
$versionlc = strtolower($version);
|
||||
// we only care about X not X.Y or X.Y.Z differences
|
||||
[$major, ] = explode('.', $versionlc);
|
||||
$versionlc = $major;
|
||||
if (version_compare($versionlc, '12', '<') || version_compare($versionlc, '16', '>')) {
|
||||
return SetupResult::warning($this->l10n->t('PostgreSQL version "%s" detected. PostgreSQL >=12 and <=16 is suggested for best performance, stability and functionality with this version of Nextcloud.', $version));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue