Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
05/28/2013 01:30:38 AM (12 years ago)
Author:
boonebgorges
Message:

Pass a default value to the first param of bp_get_the_body_class()

When bp_get_the_body_class() is run as a filter on 'body_class', the first
param is never empty. However, if you call the function directly, or in
particular if you call the echo wrapper bp_the_body_class(), you will get a
PHP error due to the fact that no default value for the function has been
provided. This changeset prevents any such errors.

Fixes #5025

Props tivnet

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-template.php

    r7100 r7113  
    15981598    echo bp_get_the_body_class();
    15991599}
    1600     function bp_get_the_body_class( $wp_classes, $custom_classes = false ) {
     1600    function bp_get_the_body_class( $wp_classes = array(), $custom_classes = false ) {
    16011601
    16021602        $bp_classes = array();
Note: See TracChangeset for help on using the changeset viewer.