<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def deindex(self, values=None, only_index=None):
 """ Deal with dicts and field names. """

        assert self.indexable, "Field not indexable"
        assert not only_index or self.has_index(only_index), "Invalid index"
        if only_index:
            only_index = only_index if isclass(only_index) else only_index.__class__

        if values is None:
            values = self.proxy_get()
        for field_name, value in iteritems(values):
            if value is not None:
                for index in self._indexes:
                    if only_index and not isinstance(index, only_index):
                        continue
                    index.remove(field_name, value)