T1378: Fix bug where tasks counters could be removed on list update

This commit is contained in:
Aleksander Machniak 2016-07-25 08:59:56 -04:00
parent 816e462359
commit 3f6f656924

View file

@ -1188,7 +1188,7 @@ function rcube_tasklist_ui(settings)
// iterate over all selector links and update counts
$('#taskselector a').each(function(i, elem){
var link = $(elem),
f = link.parent().attr('class').replace(/\s\w+/, '');
f = link.parent().attr('class').replace(/\s\w+/g, '');
if (f != 'all')
link.children('span').html(taskcounts[f] || '')[(taskcounts[f] ? 'show' : 'hide')]();
});