mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-12-26 01:50:34 +00:00
Remove counts when notifications are deleted
This commit is contained in:
parent
3fce67a60d
commit
94a41498cf
1 changed files with 2 additions and 2 deletions
|
@ -48,8 +48,8 @@ function polling(el) {
|
|||
function updateCountElement(el, data) {
|
||||
const currentCount = el.innerHTML;
|
||||
const count = data[el.getAttribute('data-poll')];
|
||||
if (count && count != currentCount) {
|
||||
removeClass(el, 'hidden');
|
||||
if (count != currentCount) {
|
||||
addRemoveClass(el, 'hidden', count < 1);
|
||||
el.innerHTML = count;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue