PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 16.3-beta
Jetpack – WP Security, Backup, Speed, & Growth v16.3-beta
16.3-beta 16.3-a.5 16.3-a.7 16.3-a.3 16.3-a.1 16.2 16.2-beta 12.0.3 12.1.3 12.2.3 12.3.2 12.4.2 12.5.2 12.6.4 12.7.3 12.8.3 12.9.5 13.0.2 13.1.5 13.2.4 13.3.3 13.4.5 13.5.2 13.6.2 13.7.2 All 507 releases
← All changes | modules/subscriptions/email-design-editor/class-jetpack-email-design-editor.php +11 -1 16.3-a.7 → 16.3-beta View file →
@@ -342,10 +342,20 @@
342 342 * @param string[] $allowed Handles to keep.
343 343 * @return array The `_wp_get_iframed_editor_assets()` shape, with `styles` filtered.
344 344 */
345 345 private static function get_resolved_assets( array $allowed ) {
346 + // Core collects the canvas's assets by buffering `wp_print_footer_scripts()`, one of the two
347 + // actions `wp_auth_check_load()` puts its "Session expired" dialog on. Core's own editor is
348 + // built before `admin_enqueue_scripts` registers that; this screen is not. NL-957.
349 + $had_auth_check = remove_action( 'wp_print_footer_scripts', 'wp_auth_check_html', 5 );
350 +
346 351 $assets = _wp_get_iframed_editor_assets();
347 - $kept = array();
352 +
353 + if ( $had_auth_check ) {
354 + add_action( 'wp_print_footer_scripts', 'wp_auth_check_html', 5 );
355 + }
356 +
357 + $kept = array();
348 358
349 359 foreach ( explode( "\n", (string) $assets['styles'] ) as $asset ) {
350 360 foreach ( $allowed as $handle ) {
351 361 if ( str_contains( $asset, $handle ) ) {