[wp-trac] [WordPress Trac] #36406: $network_wide is unreliable

WordPress Trac noreply at wordpress.org
Mon Jul 11 14:13:21 UTC 2016


#36406: $network_wide is unreliable
--------------------------+-----------------------------
 Reporter:  mensmaximus   |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Future Release
Component:  Plugins       |     Version:  4.4.2
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |     Focuses:  multisite
--------------------------+-----------------------------

Comment (by mensmaximus):

 Replying to [comment:10 earnjam]:

 > Right now 3 is the default and 1 is possible if the `Network: true`
 header is set. I could see declaring `Network: false` as serving that
 purpose.

 This is what the ticket is about and what the title says. $network_wide is
 not set consistently and therefore you cant rely on it. Please read my
 opening post again. You can exit the code after the ìf ($network_wide)`
 but you can't send a admin message to display a warning like "this plugin
 cant be activated networkwide". The problem stems from the error checking
 as explained in my comments #2, #3 and #6. The $network_wide argument
 passed to the plugin activation gets lost if the activation process raises
 an error.

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


More information about the wp-trac mailing list