<?php declare(strict_types=1);
namespace NetInventors\NetiNextProductDetailCms;
use Doctrine\DBAL\Connection;
use Shopware\Core\Framework\Plugin;
use Shopware\Core\Framework\Plugin\Context\UninstallContext;
class NetiNextProductDetailCms extends Plugin
{
public function uninstall(UninstallContext $uninstallContext): void
{
parent::uninstall($uninstallContext);
if (false === $uninstallContext->keepUserData()) {
$connection = $this->container->get(Connection::class);
if (null === $connection) {
return;
}
$connection->executeStatement(
'DROP TABLE IF EXISTS `neti_product_cms_sales_channel`, `neti_product_cms`, `neti_pdc_template_marker`'
);
}
}
}