Neos.Media/Classes/Domain/Repository/AssetRepository.php
public function remove($object)
    {
        $this->assetService->validateRemoval($object);
        parent::remove($object);
        $this->assetService->emitAssetRemoved($object);
    }
public function remove($object)
    {
        $this->assetService->validateRemoval($object);
        parent::remove($object);
        $this->assetService->emitAssetRemoved($object);
    }
public function remove ( $ object ) { $ this -> assetService -> validateRemoval ( $ object ) ; parent :: remove ( $ object ) ; $ this -> assetService -> emitAssetRemoved ( $ object ) ; }
Remove an asset while first validating if the object can be removed or
if removal is blocked because the asset is still in use.

@param AssetInterface $object
@return void
@throws IllegalObjectTypeException
@throws AssetServiceException
Remove an asset while first validating if the object can be removed or if removal is blocked because the asset is still in use .