From af07a06978d3cf99f876d0dc216faed4cc9c2fbe Mon Sep 17 00:00:00 2001 From: Niklas Neesen Date: Tue, 7 Jul 2020 09:35:57 +0200 Subject: Fixing unread-counter for office365 --- all.json | 2 +- archives/office365-owa.tar.gz | Bin 80804 -> 80804 bytes uncompressed/office365-owa/package.json | 2 +- uncompressed/office365-owa/webview.js | 4 ++-- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/all.json b/all.json index c2a1dd8..01c5717 100644 --- a/all.json +++ b/all.json @@ -675,7 +675,7 @@ "featured": false, "id": "office365-owa", "name": "Office 365 Outlook Web App", - "version": "1.1.0", + "version": "1.1.1", "icons": { "png": "https://cdn.jsdelivr.net/gh/getferdi/recipes/uncompressed/office365-owa/icon.png", "svg": "https://cdn.jsdelivr.net/gh/getferdi/recipes/uncompressed/office365-owa/icon.svg" diff --git a/archives/office365-owa.tar.gz b/archives/office365-owa.tar.gz index 243ffe9..42fcdf7 100644 Binary files a/archives/office365-owa.tar.gz and b/archives/office365-owa.tar.gz differ diff --git a/uncompressed/office365-owa/package.json b/uncompressed/office365-owa/package.json index c68f5d0..1ffb2ee 100644 --- a/uncompressed/office365-owa/package.json +++ b/uncompressed/office365-owa/package.json @@ -1,7 +1,7 @@ { "id": "office365-owa", "name": "Office 365 Outlook Web App", - "version": "1.1.0", + "version": "1.1.1", "description": "Office 365 Outlook Web App", "main": "index.js", "author": "Adam Birds ", diff --git a/uncompressed/office365-owa/webview.js b/uncompressed/office365-owa/webview.js index e144c46..ae21e19 100644 --- a/uncompressed/office365-owa/webview.js +++ b/uncompressed/office365-owa/webview.js @@ -3,7 +3,7 @@ module.exports = Franz => { const getMessages = function getMessages() { let unreadMail = 0; - + if (location.pathname.match(/\/owa/)) { // classic app unreadMail = parseInt( @@ -19,7 +19,7 @@ module.exports = Franz => { return; } - unreadMail = [...folders.parentNode.children].reduce((count, child) => { + unreadMail = [...folders.parentNode.parentNode.children].reduce((count, child) => { const unread = child.querySelector('.screenReaderOnly'); return unread && unread.textContent === 'unread' ? count + parseInt(unread.previousSibling.textContent, 10) -- cgit v1.2.3-70-g09d2