aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/stores/ServicesStore.js2
-rw-r--r--src/webview/lib/RecipeWebview.js6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/stores/ServicesStore.js b/src/stores/ServicesStore.js
index dc2cb0dbd..11915bc44 100644
--- a/src/stores/ServicesStore.js
+++ b/src/stores/ServicesStore.js
@@ -583,7 +583,7 @@ export default class ServicesStore extends Store {
583 this._shareSettingsWithServiceProcess(); 583 this._shareSettingsWithServiceProcess();
584 } else if (channel === 'alive') { 584 } else if (channel === 'alive') {
585 service.lastPollAnswer = Date.now(); 585 service.lastPollAnswer = Date.now();
586 } else if (channel === 'messages') { 586 } else if (channel === 'message-counts') {
587 debug(`Received unread message info from '${serviceId}'`, args[0]); 587 debug(`Received unread message info from '${serviceId}'`, args[0]);
588 588
589 this.actions.service.setUnreadMessageCount({ 589 this.actions.service.setUnreadMessageCount({
diff --git a/src/webview/lib/RecipeWebview.js b/src/webview/lib/RecipeWebview.js
index bb2052107..bef4b78ef 100644
--- a/src/webview/lib/RecipeWebview.js
+++ b/src/webview/lib/RecipeWebview.js
@@ -55,12 +55,12 @@ class RecipeWebview {
55 const indirectInt = parseInt(indirect, 10); 55 const indirectInt = parseInt(indirect, 10);
56 56
57 const count = { 57 const count = {
58 direct: directInt > 0 ? directInt : 0, 58 direct: Math.max(directInt, 0),
59 indirect: indirectInt > 0 ? indirectInt : 0, 59 indirect: Math.max(indirectInt, 0),
60 }; 60 };
61 61
62 62
63 ipcRenderer.sendToHost('messages', count); 63 ipcRenderer.sendToHost('message-counts', count);
64 Object.assign(this.countCache, count); 64 Object.assign(this.countCache, count);
65 65
66 debug('Sending badge count to host', count); 66 debug('Sending badge count to host', count);