refactoring
This commit is contained in:
parent
351d1b7d14
commit
6c8a3828f7
|
|
@ -39,13 +39,10 @@ export function UserContextProvider({ children }) {
|
|||
}, [language]);
|
||||
|
||||
function changeUserLanguage(newLanguage) {
|
||||
console.log(`userLanguage`, newLanguage);
|
||||
setLanguage(newLanguage);
|
||||
localStorage.setItem("userLanguage", newLanguage);
|
||||
}
|
||||
function changeCountry(newCountry) {
|
||||
console.log(`newCountry`, newCountry);
|
||||
|
||||
setCountry(newCountry);
|
||||
localStorage.setItem("userCountry", JSON.stringify(newCountry));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user