[wp-trac] [WordPress Trac] #43931: Use associative array instead of numeric for exporters and erasers

WordPress Trac noreply at wordpress.org
Wed May 2 17:52:26 UTC 2018


#43931: Use associative array instead of numeric for exporters and erasers
------------------------------------------+---------------------
 Reporter:  desrosj                       |       Owner:  (none)
     Type:  defect (bug)                  |      Status:  new
 Priority:  normal                        |   Milestone:  4.9.6
Component:  General                       |     Version:
 Severity:  normal                        |  Resolution:
 Keywords:  gdpr has-patch needs-testing  |     Focuses:
------------------------------------------+---------------------

Comment (by allendav):

 Although plugins can continue to just push onto the exporter or eraser
 arrays in the filters, it would be better (for consistency) if they now
 used a slug, e.g.:

 {{{#!php
 <?php
 function register_my_plugin_exporter( $exporters ) {
   $exporters['comment-location-plugin'] = array(
     'exporter_friendly_name' => __( 'Comment Location Plugin' ),
     'callback'               => 'my_plugin_exporter',
   );
   return $exporters;
 }

 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/43931#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list