Update src/electron-main.js

Co-authored-by: J. Ryan Stinnett <jryans@gmail.com>
This commit is contained in:
Šimon Brandner 2021-02-18 18:05:37 +01:00 committed by GitHub
parent 62b6aa26ff
commit f51acb78e0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -387,7 +387,7 @@ ipcMain.on('ipcCall', async function(ev, payload) {
}
break;
case 'setSpellCheckLanguages':
if (args[0] && args[0] != []) {
if (args[0] && args[0].length > 0) {
mainWindow.webContents.session.setSpellCheckerLanguages(args[0]);
} else {
mainWindow.webContents.session.spellcheck = false;