mirror of
https://github.com/getgrav/grav.git
synced 2025-12-05 15:29:57 +01:00
Fixed Language::getDefault() returning false and not null
This commit is contained in:
@@ -15,6 +15,7 @@
|
|||||||
* Fixed broken `Flex Page` authorization for groups
|
* Fixed broken `Flex Page` authorization for groups
|
||||||
* Fixed missing `onAdminSave` and `onAdminAfterSave` events when using `Flex Pages` and `Flex Users` [flex-objects#58](https://github.com/trilbymedia/grav-plugin-flex-objects/issues/58)
|
* Fixed missing `onAdminSave` and `onAdminAfterSave` events when using `Flex Pages` and `Flex Users` [flex-objects#58](https://github.com/trilbymedia/grav-plugin-flex-objects/issues/58)
|
||||||
* Fixed new `User Group` allowing bad group name to be saved [admin#1917](https://github.com/getgrav/grav-plugin-admin/issues/1917)
|
* Fixed new `User Group` allowing bad group name to be saved [admin#1917](https://github.com/getgrav/grav-plugin-admin/issues/1917)
|
||||||
|
* Fixed `Language::getDefault()` returning false and not null
|
||||||
|
|
||||||
# v1.7.0-rc.12
|
# v1.7.0-rc.12
|
||||||
## 06/08/2020
|
## 06/08/2020
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ class Language
|
|||||||
if (isset($default) && $this->validate($default)) {
|
if (isset($default) && $this->validate($default)) {
|
||||||
$this->default = $default;
|
$this->default = $default;
|
||||||
} else {
|
} else {
|
||||||
$this->default = reset($this->languages);
|
$this->default = !empty($this->languages) ? reset($this->languages) : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->resetFallbackPageExtensions();
|
$this->resetFallbackPageExtensions();
|
||||||
|
|||||||
Reference in New Issue
Block a user