diff options
Diffstat (limited to 'recipes/onmail/webview.js')
-rw-r--r-- | recipes/onmail/webview.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/recipes/onmail/webview.js b/recipes/onmail/webview.js index 8565d76..9e881f4 100644 --- a/recipes/onmail/webview.js +++ b/recipes/onmail/webview.js | |||
@@ -10,7 +10,9 @@ module.exports = Ferdium => { | |||
10 | const inboxLinks = document.querySelectorAll('p.truncate'); | 10 | const inboxLinks = document.querySelectorAll('p.truncate'); |
11 | for (const label of inboxLinks){ | 11 | for (const label of inboxLinks){ |
12 | if (label.textContent) { | 12 | if (label.textContent) { |
13 | countImportant = Ferdium.safeParseInt(label.nextSibling.textContent); | 13 | let inbox_count = label.nextSibling |
14 | countImportant = inbox_count == null ? 0 : Ferdium.safeParseInt(inbox_count.textContent); | ||
15 | |||
14 | break; | 16 | break; |
15 | } | 17 | } |
16 | } | 18 | } |