Skip to content

Commit

Permalink
fix: localisation 4 im embarassed
Browse files Browse the repository at this point in the history
  • Loading branch information
puppy-girl committed Sep 22, 2024
1 parent 9ba87c0 commit 095bf95
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions scripts/localisation.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@ let currentLocale = defaultLocale;
if (localStorage.getItem('locale')) {
const storedLocale = localStorage.getItem('locale');

if (!supportedLocales.includes(storedLocale))
return localStorage.removeItem('locale');

currentLocale = localStorage.getItem('locale');
if (!supportedLocales.includes(storedLocale)) {
localStorage.removeItem('locale');
} else {
currentLocale = localStorage.getItem('locale');
}
}

let localisations = {};
Expand Down

0 comments on commit 095bf95

Please sign in to comment.