bug fix for tasks-count