From 29f3dc2fa351746f50b87cf7b147ab5055b79fa2 Mon Sep 17 00:00:00 2001 From: Mario Date: Mon, 11 Oct 2021 09:12:05 +0000 Subject: notifications_widget: fix regression hiding the #nav- * -sub element when there are no more notifications --- view/tpl/notifications_widget.tpl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'view') diff --git a/view/tpl/notifications_widget.tpl b/view/tpl/notifications_widget.tpl index 3b75cea31..fcadf71e5 100644 --- a/view/tpl/notifications_widget.tpl +++ b/view/tpl/notifications_widget.tpl @@ -315,6 +315,7 @@ } else { $('.' + type + '-update').html('0'); + $('#nav-' + type + '-sub').removeClass('show'); $('.' + type + '-button').fadeOut(function() { sse_setNotificationsStatus(); }); @@ -490,9 +491,10 @@ var fcount = Number($('.' + n[1] + '-update').html()); fcount--; $('.' + n[1] + '-update').html(fcount); - if(fcount < 1) + if(fcount < 1) { $('.' + n[1] + '-button').fadeOut(); - + $('#nav-' + n[1] + '-sub').removeClass('show'); + } var count = Number($(this).find('.bg-secondary').html()); count--; $(this).find('.bg-secondary').html(count); -- cgit v1.2.3