will pendingTasks.remove() ever be null?