From 804d22a06447b0a8ab6acab2aca7f02d939d2d62 Mon Sep 17 00:00:00 2001 From: Vijay Aravamudhan Date: Sat, 11 Sep 2021 23:12:08 +0530 Subject: fix issue with Office365 not getting unread counts in non-english locale (fixes #679) (#681) --- recipes/office365-owa/package.json | 2 +- recipes/office365-owa/webview.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'recipes') diff --git a/recipes/office365-owa/package.json b/recipes/office365-owa/package.json index 3d13fef..bd3ca9c 100644 --- a/recipes/office365-owa/package.json +++ b/recipes/office365-owa/package.json @@ -1,7 +1,7 @@ { "id": "office365-owa", "name": "Office 365 Outlook", - "version": "1.4.4", + "version": "1.4.5", "license": "MIT", "aliases": [ "live.com" diff --git a/recipes/office365-owa/webview.js b/recipes/office365-owa/webview.js index 1a04132..82c7dfd 100644 --- a/recipes/office365-owa/webview.js +++ b/recipes/office365-owa/webview.js @@ -12,7 +12,7 @@ module.exports = Ferdi => { if (foldersElement) { const allScreenReaders = foldersElement.querySelectorAll('span.screenReaderOnly'); for (const child of allScreenReaders) { - if ((child.innerText === 'unread' || child.innerText === 'item') && child.previousSibling) { + if (child.previousSibling) { directUnreadCount += Ferdi.safeParseInt(child.previousSibling.innerText); } } @@ -22,7 +22,7 @@ module.exports = Ferdi => { if (groupsElement) { const allScreenReaders = groupsElement.querySelectorAll('span.screenReaderOnly'); for (const child of allScreenReaders) { - if ((child.innerText === 'unread' || child.innerText === 'item') && child.previousSibling) { + if (child.previousSibling) { indirectUnreadCount += Ferdi.safeParseInt(child.previousSibling.innerText); } } -- cgit v1.2.3-54-g00ecf