code: def _unregister(self, cls):
          
          if not issubclass(cls, self._registerable_class):
              raise ValueError('Only %s classes or subclasses may be '
                               'unregistered.' % self._registerable_class)
  
          if cls not in self._registry:
              raise NotRegistered('%s is not registered' % cls)
  
          del self._registry[cls]
  
          return True
docs: Unregisters the given class.
  
          If the specified class isn't registered, ``NotRegistered`` will
          be raised.