fix: use wp_clear_scheduled_hook to properly clear all cron events
This commit is contained in:
14
includes/class-peptide-news-deactivator.php
Normal file
14
includes/class-peptide-news-deactivator.php
Normal file
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
/**
|
||||
* Fired during plugin deactivation.
|
||||
*
|
||||
* Clears scheduled cron events. Does NOT drop tables (data preservation).
|
||||
*
|
||||
* @since 1.0.0
|
||||
*/
|
||||
class Peptide_News_Deactivator {
|
||||
|
||||
public static function deactivate() {
|
||||
wp_clear_scheduled_hook( 'peptide_news_cron_fetch' );
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user