[wp-trac] [WordPress Trac] #28102: is_string check in validate_file

WordPress Trac noreply at wordpress.org
Fri May 2 09:10:22 UTC 2014


#28102: is_string check in validate_file
----------------------------------+------------------------------
 Reporter:  IwanLuijksQuestMedia  |       Owner:
     Type:  defect (bug)          |      Status:  new
 Priority:  normal                |   Milestone:  Awaiting Review
Component:  Plugins               |     Version:  3.9
 Severity:  normal                |  Resolution:
 Keywords:                        |     Focuses:  administration
----------------------------------+------------------------------

Comment (by IwanLuijksQuestMedia):

 This happens when in the plugin itself you use the variable $plugin, as
 in:
 {{{
 #!php
 <?php
 $plugin = \SomeQM\Plugin::instantiate();
 $plugin->expose_hooks();
 }}}

 While the following doesn't trigger the errors:
 {{{
 #!php
 <?php
 $plugin2 = \SomeQM\Plugin::instantiate();
 $plugin2->expose_hooks();
 }}}

 This is really bad side-effect behaviour, and should be fixed, or at least
 fully documented somewhere.

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


More information about the wp-trac mailing list