Main+Utils: Rename `getLocale` function to `getSystemLocale`

This commit is contained in:
Svallinn 2021-06-20 02:42:11 +01:00
parent 5cc954066b
commit d3e6d57f20
No known key found for this signature in database
GPG Key ID: 09FB527F34037CCA
2 changed files with 3 additions and 3 deletions

View File

@ -335,7 +335,7 @@ function runApp() {
if (typeof url === 'string') shell.openExternal(url) if (typeof url === 'string') shell.openExternal(url)
}) })
ipcMain.handle('getLocale', () => { ipcMain.handle('getSystemLocale', () => {
return app.getLocale() return app.getLocale()
}) })

View File

@ -153,14 +153,14 @@ const actions = {
} }
}, },
async getLocale (context) { async getSystemLocale (context) {
const webCbk = () => { const webCbk = () => {
if (navigator && navigator.language) { if (navigator && navigator.language) {
return 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) { async showOpenDialog (context, options) {