diff --git a/CHANGELOG-v3.md b/CHANGELOG-v3.md index 4d63af275b5..5a2ae78deb4 100644 --- a/CHANGELOG-v3.md +++ b/CHANGELOG-v3.md @@ -5,6 +5,7 @@ ### Fixed - Fixed a bug where renaming an asset file was impossible using the element action. ([#3707](https://github.com/craftcms/cms/issues/3707)) - Fixed a bug where saving user details would result in a PHP error. +- Fixed a bug where it was impossible to apply project config changes. ([#3713](https://github.com/craftcms/cms/issues/3713)) ## 3.1.4 - 2019-01-24 diff --git a/src/services/ProjectConfig.php b/src/services/ProjectConfig.php index cdd0d578898..c8ea44b8dfa 100644 --- a/src/services/ProjectConfig.php +++ b/src/services/ProjectConfig.php @@ -665,7 +665,7 @@ public function getAreConfigSchemaVersionsCompatible(): bool $existingSchema = (string)Craft::$app->schemaVersion; // Compare existing Craft schema version with the one that is being applied. - if (version_compare($existingSchema, $incomingSchema, '=')) { + if (!version_compare($existingSchema, $incomingSchema, '=')) { return false; } @@ -677,7 +677,7 @@ public function getAreConfigSchemaVersionsCompatible(): bool $existingSchema = (string)$plugin->schemaVersion; // Compare existing plugin schema version with the one that is being applied. - if (version_compare($existingSchema, $incomingSchema, '=')) { + if ($incomingSchema && !version_compare($existingSchema, $incomingSchema, '=')) { return false; } }