Updating todos with different events and searching by id