server, electron: Fix crash if locale is undefined

This commit is contained in:
Elian Doran
2024-10-12 18:24:10 +03:00
parent 729a188528
commit bae63b08a2

View File

@@ -18,7 +18,7 @@ export async function initializeTranslations() {
function getCurrentLanguage() { function getCurrentLanguage() {
let language; let language;
if (sql_init.isDbInitialized()) { if (sql_init.isDbInitialized()) {
language = options.getOption("locale"); language = options.getOptionOrNull("locale");
} }
if (!language) { if (!language) {