Fix bug in categoryList in TaskManager