<?php declare(strict_types=1);
namespace ApplifactionTextModules;
use ApplifactionTextModules\Compatibility\DependencyLoader;
use Shopware\Core\Framework\Plugin;
use Shopware\Core\Framework\Plugin\Context\UninstallContext;
class ApplifactionTextModules extends Plugin
{
public function uninstall(UninstallContext $uninstallContext): void
{
parent::uninstall($uninstallContext);
if ($uninstallContext->keepUserData()) {
return;
}
$this->dropTables();
}
private function dropTables(): void
{
$connection = $this->container->get(Connection::class);
$connection->executeUpdate('DROP TABLE IF EXISTS `text_module`');
}
}