diff --git a/src/Extension.ts b/src/Extension.ts index 25e084f6..5425c568 100644 --- a/src/Extension.ts +++ b/src/Extension.ts @@ -33,7 +33,6 @@ export default class Extension { await CacheAuth.cachePassword(); await AccountManager.saveBackup(recoveryPhrase); } catch (error) { - console.error(error); throw new Error(error as string); } } @@ -132,7 +131,6 @@ export default class Extension { if (!accounts) return false; return AccountManager.areAccountsInitialized(accounts); } catch (error) { - console.error(error); return false; } } @@ -217,7 +215,10 @@ export default class Extension { return settings.getAll(SettingType.ADVANCED); } - static async getSetting(type: SettingType, key: SettingKey): Promise { + static async getSetting( + type: SettingType, + key: SettingKey + ): Promise { const settings = await Settings.get(); if (!settings) throw new Error("failed_to_get_settings"); return settings.get(type, key); diff --git a/src/pages/settings/General.tsx b/src/pages/settings/General.tsx index d197d01f..6fa93ad2 100644 --- a/src/pages/settings/General.tsx +++ b/src/pages/settings/General.tsx @@ -119,7 +119,7 @@ export const General = () => { data-testid="language-select" className="text-sm rounded-lg focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5 bg-gray-700 border-gray-600 placeholder-gray-400 text-white" onChange={(e) => saveLanguage(e.target.value)} - value={selectedLanguage} + value={selectedLanguage || ""} > {setting.isLanguageArray() && (setting.value as Language[]).map((option, index) => ( @@ -159,7 +159,7 @@ export const General = () => {