disableVersion, we will remove the entry from the table 'versions' and 'plugin_settings' // because the plugins cannot be used any more DB::table('versions') ->where('product_type', '=', 'plugins.generic') ->where('product', '=', 'usageStats') ->delete(); DB::table('plugin_settings') ->where('plugin_name', '=', 'usagestatsplugin') ->delete(); DB::table('versions') ->where('product_type', '=', 'plugins.reports') ->where('product', '=', 'views') ->delete(); // It is not needed to remove usageStats plugin scheduled task from the Acron plugin, because // PKPAcronPlugin function _parseCrontab() will be called at the end of update, that // will overwrite the old crontab setting. // Remove the old scheduled task from the table scheduled_tasks DB::table('scheduled_tasks')->where('class_name', '=', 'plugins.generic.usageStats.UsageStatsLoader')->delete(); } /** * Reverse the downgrades * * @throws DowngradeNotSupportedException */ public function down(): void { throw new DowngradeNotSupportedException(); } }