diff --git a/src/Uninstall.php b/src/Uninstall.php new file mode 100644 index 0000000..abfccc1 --- /dev/null +++ b/src/Uninstall.php @@ -0,0 +1,82 @@ +plugins->moduleExists('Uninstaller')) { + return false; + } + + Uninstaller::instance() + ->addUserAction( + 'settings', + 'delete_all', + My::id() + ) + ->addUserAction( + 'tables', + 'delete', + My::TABLE_NAME + ) + ->addUserAction( + 'plugins', + 'delete', + My::id() + ) + ->addUserAction( + 'versions', + 'delete', + My::id() + ) + ->addDirectAction( + 'settings', + 'delete_all', + My::id() + ) + ->addDirectAction( + 'tables', + 'delete', + My::TABLE_NAME + ) + ->addDirectAction( + 'plugins', + 'delete', + My::id() + ) + ->addDirectAction( + 'versions', + 'delete', + My::id() + ) + ; + + // no custom action + return false; + } +}