Fix task index