/**
  * {@inheritdoc}
  */
 public function rollback()
 {
     // sanity check
     if ($this->typeDescriptor->isLoaded() || !$this->containingModule) {
         return;
     }
     // never fails with the check before
     $this->typeDescriptor->load($this->containingModule);
     if ($this->wasRemoved) {
         // never fails
         $this->typeDescriptors->add($this->typeDescriptor);
     }
 }
 /**
  * {@inheritdoc}
  */
 public function rollback()
 {
     // sanity check
     if (!$this->typeDescriptor->isLoaded()) {
         return;
     }
     $typeName = $this->typeDescriptor->getTypeName();
     // never fails with the check before
     $this->typeDescriptor->unload();
     if ($this->previousDescriptor && $this->previousDescriptor->isLoaded()) {
         // never fails
         $this->typeDescriptors->add($this->previousDescriptor);
     } else {
         // never fails
         $this->typeDescriptors->remove($typeName, $this->containingPackage->getName());
     }
 }