diff options
author | 2017-12-07 22:05:21 +0100 | |
---|---|---|
committer | 2017-12-07 22:05:21 +0100 | |
commit | adbf2e7ae7358cfa1502e010ad38c62d521adae9 (patch) | |
tree | 96297f7ce1e9e7f64cf9e86af3313e8618582c8b /src/webview/lib/RecipeWebview.js | |
parent | feat(App): Register franz:// as an URL handler to control the app from extern... (diff) | |
parent | Fix bug that allows negative badge notifications (diff) | |
download | ferdium-app-adbf2e7ae7358cfa1502e010ad38c62d521adae9.tar.gz ferdium-app-adbf2e7ae7358cfa1502e010ad38c62d521adae9.tar.zst ferdium-app-adbf2e7ae7358cfa1502e010ad38c62d521adae9.zip |
fix(App): Fix negative badge numbers (@RazvanDH)
Fix bug that allows negative badge notifications
Diffstat (limited to 'src/webview/lib/RecipeWebview.js')
-rw-r--r-- | src/webview/lib/RecipeWebview.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/webview/lib/RecipeWebview.js b/src/webview/lib/RecipeWebview.js index 048beea69..be29142af 100644 --- a/src/webview/lib/RecipeWebview.js +++ b/src/webview/lib/RecipeWebview.js | |||
@@ -40,8 +40,8 @@ class RecipeWebview { | |||
40 | && this.countCache.indirect === indirect) return; | 40 | && this.countCache.indirect === indirect) return; |
41 | 41 | ||
42 | const count = { | 42 | const count = { |
43 | direct, | 43 | direct: direct > 0 ? direct : 0, |
44 | indirect, | 44 | indirect: indirect > 0 ? indirect : 0, |
45 | }; | 45 | }; |
46 | 46 | ||
47 | ipcRenderer.sendToHost('messages', count); | 47 | ipcRenderer.sendToHost('messages', count); |