From a48473673fb132d284ce30cdb699c44c951cf784 Mon Sep 17 00:00:00 2001 From: Vitaliy Filippov Date: Sun, 2 Dec 2018 14:44:14 +0300 Subject: [PATCH] fix int --- Store.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Store.js b/Store.js index 6582dd3..e7cc51f 100644 --- a/Store.js +++ b/Store.js @@ -122,11 +122,12 @@ var Store = module.exports = { { let icon = (account.folderTypes[f.name] ? 'mail_'+account.folderTypes[f.name] : 'folder'); account.folders.push({ name: f.name, icon: icon, unreadCount: f.unread_count-0, folderId: f.id }); - account.folders[0].unreadCount -= -f.unread_count; + account.folders[0].unreadCount += (f.unread_count-0); if (account.folderTypes[f.name]) { - accounts[0].folders[ixOfAll[account.folderTypes[f.name]]].unreadCount -= -f.unread_count; + accounts[0].folders[ixOfAll[account.folderTypes[f.name]]].unreadCount += (f.unread_count-0); } + account.unreadCount += (f.unread_count-0); } accounts.push(account); accounts[0].unreadCount += account.unreadCount;