Added id validation for update and remove methods.