Make WordPress Core


Ignore:
Timestamp:
06/10/2010 04:07:33 PM (15 years ago)
Author:
nacin
Message:

Move 'helps' argument to the taxonomy labels object. Also move over help_nojs and help_cloud, both introduced in 3.0. This adds three new core labels for non-hierarchical taxonomies, for tweaking the meta box strings. fixes #13805.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/post.php

    r15188 r15190  
    967967function _get_custom_object_labels( $object, $nohier_vs_hier_defaults ) {
    968968
    969     if ( isset( $object->label ) ) {
     969    if ( isset( $object->label ) && empty( $object->labels['name'] ) )
    970970        $object->labels['name'] = $object->label;
    971     }
    972 
    973     if ( !isset( $object->labels['singular_name'] ) && isset( $object->labels['name'] ) ) {
     971
     972    if ( !isset( $object->labels['singular_name'] ) && isset( $object->labels['name'] ) )
    974973        $object->labels['singular_name'] = $object->labels['name'];
    975     }
    976974
    977975    $defaults = array_map( create_function( '$x', $object->hierarchical? 'return $x[1];' : 'return $x[0];' ), $nohier_vs_hier_defaults );
Note: See TracChangeset for help on using the changeset viewer.