From 3ae5f84ec3425b0ab6dca731fecfb6dad46c4dfd Mon Sep 17 00:00:00 2001 From: TheGoddessInari Date: Sun, 15 Sep 2019 14:36:45 -0700 Subject: [PATCH] Revert "Normalize badge updates at the source." This reverts commit 461052bdcfbfd3f97b91eb9ea678872635506e5d. --- app/ux/WebView.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/ux/WebView.js b/app/ux/WebView.js index e950a073..6dd152fe 100644 --- a/app/ux/WebView.js +++ b/app/ux/WebView.js @@ -565,11 +565,11 @@ Ext.define('Hamsket.ux.WebView',{ function handleUpdateBadge(event) { if (Array.isArray(event.args) === true && event.args.length > 1) { - const direct = parseInt(event.args[0], 10) || 0; - const indirect = parseInt(event.args[1], 10) || 0; + const direct = event.args[0]; + const indirect = event.args[1]; const count = direct > 0 ? direct : (indirect > 0 ? '•' : 0); - if (count > 0 || count === '•') { + if (count === parseInt(count, 10) || count === '•') { me.setUnreadCount(count); } else { me.handleClearUnreadCount();