Array.isArray to isArray

Array.isNotEmpty to isNonEmptyArray
This commit is contained in:
djmaze 2021-03-16 16:49:14 +01:00
parent 986b8f056b
commit 0b64083543
30 changed files with 82 additions and 69 deletions

View file

@ -1,5 +1,6 @@
import ko from 'ko';
import { Settings, SettingsGet } from 'Common/Globals';
import { isArray } from 'Common/Utils';
export const LanguageStore = {
languages: ko.observableArray(),
@ -7,7 +8,7 @@ export const LanguageStore = {
populate: function() {
const aLanguages = Settings.app('languages');
this.languages(Array.isArray(aLanguages) ? aLanguages : []);
this.languages(isArray(aLanguages) ? aLanguages : []);
this.language(SettingsGet('Language'));
this.userLanguage(SettingsGet('UserLanguage'));
}