code: def delete(self, location_name):
          
          updated = False
          location_ref = location_helper(location_name, search_only=True)
          if location_ref in self:
              self._cas[:] = [loc for loc in self
                  if loc.location_ref != location_ref]
              self.update()
              updated = True
          return updated
docs: Remove a given location by location name. This operation is
          performed only if the given location is valid, and if so,
          `update` is called automatically.
          
          :param str location: location name or location ref
          :raises UpdateElementFailed: failed to update element with reason
          :rtype: bool