Skip to content

Commit

Permalink
Re-register post_statuses on locale change, to ensure they have the c…
Browse files Browse the repository at this point in the history
…orrect label locales
  • Loading branch information
dd32 authored Nov 25, 2024
1 parent 86f6983 commit 357c2b2
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ public function __construct() {
add_action( 'plugins_loaded', array( $this, 'includes' ) );
add_action( 'init', array( $this, 'register_post_types' ) );
add_action( 'init', array( $this, 'register_post_statuses' ) );
add_action( 'change_locale', array( $this, 'register_post_statuses' ) ); // Re-register them when the locale changes, to have localised statuses.
add_filter( 'pre_get_posts', array( $this, 'query_public_statuses_on_archives' ) );
add_filter( 'cron_schedules', array( $this, 'add_weekly_cron_interval' ) );
}
Expand Down

0 comments on commit 357c2b2

Please sign in to comment.