File "DestroyCommand.php"
Full Path: /home/clickysoft/public_html/jmapi5.clickysoft.net/vendor/intervention/image/src/Intervention/Image/Imagick/Commands/DestroyCommand.php
File size: 559 bytes
MIME-type: text/x-php
Charset: utf-8
<?php
namespace Intervention\Image\Imagick\Commands;
use Intervention\Image\Commands\AbstractCommand;
class DestroyCommand extends AbstractCommand
{
/**
* Destroys current image core and frees up memory
*
* @param \Intervention\Image\Image $image
* @return boolean
*/
public function execute($image)
{
// destroy image core
$image->getCore()->clear();
// destroy backups
foreach ($image->getBackups() as $backup) {
$backup->clear();
}
return true;
}
}