Skip to:
Content

BuddyPress.org

Changeset 11365


Ignore:
Timestamp:
01/02/2017 07:51:45 PM (7 years ago)
Author:
tw2113
Message:

Adds field IDs to bp_get_the_profile_field_is_required and bp_get_the_profile_field_visibility_level filters.

Fixes #6086.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-xprofile/bp-xprofile-template.php

    r11360 r11365  
    816816         *
    817817         * @since 1.1.0
     818         * @since 2.8.0 Added field ID.
    818819         *
    819820         * @param bool $retval Whether or not the field is required.
    820          */
    821         return (bool) apply_filters( 'bp_get_the_profile_field_is_required', $retval );
     821         * @param int  $value  Field ID that may be required.
     822         */
     823        return (bool) apply_filters( 'bp_get_the_profile_field_is_required', $retval, $field->id );
    822824    }
    823825
     
    854856         *
    855857         * @since 1.6.0
     858         * @since 2.8.0 Added field ID.
    856859         *
    857860         * @param string $retval Field visibility level.
    858          */
    859         return apply_filters( 'bp_get_the_profile_field_visibility_level', $retval );
     861         * @param int    $value  Field ID.
     862         */
     863        return apply_filters( 'bp_get_the_profile_field_visibility_level', $retval, $field->id );
    860864    }
    861865
Note: See TracChangeset for help on using the changeset viewer.