Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
09/12/2021 08:43:39 PM (4 years ago)
Author:
espellcaste
Message:

Update all references from wp_parse_args to bp_parse_args.

Also, add WPCS improvements to align bp_parse_args correctly.

Props imath
Fixes #8564

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/bp-core-cache.php

    r12898 r13108  
    200200    global $wpdb;
    201201
    202     $defaults = array(
    203         'object_ids'       => array(), // Comma-separated list or array of item ids.
    204         'object_type'      => '',      // Canonical component id: groups, members, etc.
    205         'cache_group'      => '',      // Cache group.
    206         'meta_table'       => '',      // Name of the table containing the metadata.
    207         'object_column'    => '',      // DB column for the object ids (group_id, etc).
    208         'cache_key_prefix' => ''       // Prefix to use when creating cache key names. Eg 'bp_groups_groupmeta'.
     202    $r = bp_parse_args(
     203        $args,
     204        array(
     205            'object_ids'       => array(), // Comma-separated list or array of item ids.
     206            'object_type'      => '',      // Canonical component id: groups, members, etc.
     207            'cache_group'      => '',      // Cache group.
     208            'meta_table'       => '',      // Name of the table containing the metadata.
     209            'object_column'    => '',      // DB column for the object ids (group_id, etc).
     210            'cache_key_prefix' => '',      // Prefix to use when creating cache key names. Eg 'bp_groups_groupmeta'.
     211        )
    209212    );
    210     $r = wp_parse_args( $args, $defaults );
     213
    211214    extract( $r );
    212215
Note: See TracChangeset for help on using the changeset viewer.