Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
05/07/2020 07:23:00 PM (6 years ago)
Author:
r-a-y
Message:

Do not use sanitize_file_name() when passing integer values.

Fixes an array offset notice due to the addition of seems_utf8() in
sanitize_file_name() for WordPress 5.4.1:
https://core.trac.wordpress.org/changeset/47643

Props mercime, r-a-y.

Fixes #8288.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/classes/class-bp-groups-theme-compat.php

    r11151 r12647  
    224224         */
    225225        $new_templates = apply_filters( 'bp_template_hierarchy_groups_single_item', array(
    226             'groups/single/index-id-'     . sanitize_file_name( bp_get_current_group_id() )   . '.php',
     226            'groups/single/index-id-'     . (int) bp_get_current_group_id()                   . '.php',
    227227            'groups/single/index-slug-'   . sanitize_file_name( bp_get_current_group_slug() ) . '.php',
    228228            'groups/single/index-action-' . sanitize_file_name( bp_current_action() )         . '.php',
Note: See TracChangeset for help on using the changeset viewer.