[wp-trac] [WordPress Trac] #22250: Useful helper function, add_action_with_args()

WordPress Trac noreply at wordpress.org
Mon Oct 22 02:35:10 UTC 2012


#22250: Useful helper function, add_action_with_args()
-------------------------+------------------------------
 Reporter:  rzen         |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  Awaiting Review
Component:  General      |     Version:
 Severity:  normal       |  Resolution:
 Keywords:  2nd-opinion  |
-------------------------+------------------------------

Comment (by DrewAPicture):

 Feel free to correct me on any of this.

 Isn't it possible that using this helper in core could actually make it
 more difficult to extend certain functionality? I mean, I'm no great
 shakes of a developer but it seems like most of the time functions are
 abstracted so we have the ability to manipulate returned values in
 callbacks, such as through filters, separate from the actions.

 The way I read this is that `add_action_with_args()` would essentially
 allow rolling a callback + args into add_action, without the added
 abstraction layer. I can see how it might 'save time', but I can also see
 how it might create an an extensibility barrier.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/22250#comment:5>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list