diff --git a/src/main/index.js b/src/main/index.js index 502f889cb..a0fc0bcc2 100644 --- a/src/main/index.js +++ b/src/main/index.js @@ -335,7 +335,7 @@ function runApp() { if (typeof url === 'string') shell.openExternal(url) }) - ipcMain.handle('getLocale', () => { + ipcMain.handle('getSystemLocale', () => { return app.getLocale() }) diff --git a/src/renderer/store/modules/utils.js b/src/renderer/store/modules/utils.js index 06cec337d..d47c7d283 100644 --- a/src/renderer/store/modules/utils.js +++ b/src/renderer/store/modules/utils.js @@ -153,14 +153,14 @@ const actions = { } }, - async getLocale (context) { + async getSystemLocale (context) { const webCbk = () => { if (navigator && navigator.language) { return navigator.language } } - return await invokeIRC(context, 'getLocale', webCbk) || 'en-US' + return (await invokeIRC(context, 'getSystemLocale', webCbk)) || 'en-US' }, async showOpenDialog (context, options) {