Skip to content

A local-first personal finance app

🐛 Fix the default language init for electron (#4439)

lelemmf413fa03ae8f
diff --git a/packages/desktop-client/src/components/App.tsx b/packages/desktop-client/src/components/App.tsx
index 50fead5553..98a0426d98 100644
--- a/packages/desktop-client/src/components/App.tsx
+++ b/packages/desktop-client/src/components/App.tsx
@@ -53,6 +53,10 @@ function AppInner() {
const dispatch = useDispatch();
const userData = useSelector(state => state.user.data);
+ useEffect(() => {
+ setI18NextLanguage(null);
+ }, []);
+
useEffect(() => {
const maybeUpdate = async <T,>(cb?: () => T): Promise<T> => {
if (global.Actual.isUpdateReadyForDownload()) {
@@ -67,8 +71,6 @@ function AppInner() {
};
async function init() {
- setI18NextLanguage(null);
-
const socketName = await maybeUpdate(() =>
global.Actual.getServerSocket(),
);
diff --git a/upcoming-release-notes/4439.md b/upcoming-release-notes/4439.md
new file mode 100644
index 0000000000..920a867b60
--- /dev/null
+++ b/upcoming-release-notes/4439.md
@@ -0,0 +1,6 @@
+---
+category: Bugfix
+authors: [lelemm]
+---
+
+Fix the default language init for electron