Skip to content

Commit e9ced2c

Browse files
Administration: Restore backward compat in deprecated options JS functions
1 parent 28ffeea commit e9ced2c

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/wp-admin/includes/deprecated.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1599,6 +1599,7 @@ function image_attachment_fields_to_save( $post, $attachment ) {
15991599
*/
16001600
function options_discussion_add_js() {
16011601
_deprecated_function( __FUNCTION__, '7.1.0' );
1602+
wp_enqueue_script( 'options' );
16021603
}
16031604

16041605
/**
@@ -1610,6 +1611,8 @@ function options_discussion_add_js() {
16101611
*/
16111612
function options_general_add_js() {
16121613
_deprecated_function( __FUNCTION__, '7.1.0' );
1614+
wp_enqueue_script( 'options' );
1615+
wp_localize_script( 'options', 'optionsL10n', array( 'homeURL' => get_home_url() ) );
16131616
}
16141617

16151618
/**
@@ -1621,4 +1624,5 @@ function options_general_add_js() {
16211624
*/
16221625
function options_reading_add_js() {
16231626
_deprecated_function( __FUNCTION__, '7.1.0' );
1627+
wp_enqueue_script( 'options' );
16241628
}

0 commit comments

Comments
 (0)