Replace with getTaskIndexInList