Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
09/17/2016 04:54:21 PM (10 years ago)
Author:
dcavins
Message:

Member Types: Use helper function for taxonomy name.

Allows the member type taxonomy name to be filtered.

Props slaFFik, dcavins.

See #6060.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/testcases/members/types.php

    r11045 r11110  
    286286
    287287                // Fetch a term ID.
    288                 $terms = get_terms( 'bp_member_type', array( 'hide_empty' => false, 'fields' => 'all' ) );
     288                $terms = get_terms( bp_get_member_type_tax_name(), array( 'hide_empty' => false, 'fields' => 'all' ) );
    289289
    290290                // Make sure the user's ID matches a term ID, to force a cache confusion.
    … …  
    296296
    297297                // Reprime the taxonomy cache.
    298                 $terms = get_terms( 'bp_member_type', array( 'hide_empty' => false, 'fields' => 'all' ) );
     298                $terms = get_terms( bp_get_member_type_tax_name(), array( 'hide_empty' => false, 'fields' => 'all' ) );
    299299
    300300                $this->assertSame( 'foo', bp_get_member_type( $new_user_id, true ) );
    … …  
    400400
    401401                // Directly set a type that hasn't been registered.
    402                 bp_set_object_terms( $u1, 'ugh', 'bp_member_type', true );
     402                bp_set_object_terms( $u1, 'ugh', bp_get_member_type_tax_name(), true );
    403403
    404404                $type = bp_get_member_type( $u1, false );
Note: See TracChangeset for help on using the changeset viewer.