Skip to content

Commit

Permalink
Disable 'pageview', 'wp_mail', 'plugin_updated' events
Browse files Browse the repository at this point in the history
  • Loading branch information
BrianHenryIE committed Oct 17, 2024
1 parent f7eee76 commit 17926a8
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions includes/EventManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,14 @@ public function add_minutely_schedule( $schedules ) {
*/
public function shutdown(): void {

// Due to a bug sending too many events, we are temporarily disabling these.
$disabled_events = array( 'pageview', 'wp_mail', 'plugin_updated' );
foreach ( $this->queue as $index => $event ) {
if ( in_array( $event->key, $disabled_events, true ) ) {
unset( $this->queue[ $index ] );
}
}

// Separate out the async events
$async = array();
foreach ( $this->queue as $index => $event ) {
Expand Down

0 comments on commit 17926a8

Please sign in to comment.