Make WordPress Core


Ignore:
Timestamp:
06/23/2020 06:53:00 PM (5 years ago)
Author:
desrosj
Message:

General: Rename (add|remove)_option_allowed_list() to (add|remove)_allowed_option().

The new names make the purpose more clear. It also adds consistency with the $allowed_options global variable.

Also in this change, the wp-deprecated dependency has been removed from the password strength meter in favor of a window.console.log() call to avoid adding 3 dependencies for one deprecated notice.

Props SergeyBiryukov, ocean90, desrosj
Fixes #50413.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/deprecated.php

    r48121 r48142  
    40434043 *
    40444044 * @since 2.7.0
    4045  * @deprecated 5.5.0 Use add_option_allowed_list() instead.
     4045 * @deprecated 5.5.0 Use add_allowed_options() instead.
    40464046 *                   Please consider writing more inclusive code.
    40474047 *
     
    40534053 */
    40544054function add_option_whitelist( $new_options, $options = '' ) {
    4055     _deprecated_function( __FUNCTION__, '5.5.0', 'add_option_allowed_list()' );
    4056 
    4057     return add_option_allowed_list( $new_options, $options );
     4055    _deprecated_function( __FUNCTION__, '5.5.0', 'add_allowed_options()' );
     4056
     4057    return add_allowed_options( $new_options, $options );
    40584058}
    40594059
Note: See TracChangeset for help on using the changeset viewer.