<?php declare(strict_types=1);
namespace CrayssnLabsConfigurator;
use Shopware\Core\Framework\Api\Context\SystemSource;
use Shopware\Core\Framework\Context;
use Shopware\Core\Framework\Plugin;
/**
* Class CrayssnLabsConfigurator
*
* @package CrayssnLabsConfigurator
*
* @author Sebastian Ludwig <dev@cl.team>
* @copyright Copyright (c) 2020, CrayssnLabs Ludwig Wiegler GbR
*
* sudo apt update ; sudo apt install -y imagemagick imagemagick-doc ffmpeg webp nano libheif-examples
*
* ImageMagic did not allow to process pdf files with convert. To remove this
* policy entry:
* sudo nano /etc/ImageMagick-6/policy.xml
* replace <policy domain="coder" rights="none" pattern="PDF" /> with <!--<policy domain="coder" rights="none" pattern="PDF" />-->
*/
class CrayssnLabsConfigurator extends Plugin
{
/**
* Function getContext
*
* @return \Shopware\Core\Framework\Context
*/
public static function getContext(): Context
{
static $context;
if($context === null)
{
$context = new Context(new SystemSource());
}
return $context;
}
}