public static function create()
{
try {
if (extension_loaded("imagick")) {
return new Adapter\Imagick();
} else {
return new Adapter\GD();
}
} catch (\Exception $e) {
Logger::crit("Unable to load image extensions: " . $e->getMessage());
throw $e;
}
}