[wp-trac] [WordPress Trac] #25301: Warning when displaying a Drop-in whose Constant is not defined in wp-config.php

WordPress Trac noreply at wordpress.org
Fri Sep 13 00:17:52 UTC 2013


#25301: Warning when displaying a Drop-in whose Constant is not defined in wp-
config.php
---------------------------+-----------------------------
 Reporter:  adiant         |      Owner:
     Type:  defect (bug)   |     Status:  new
 Priority:  normal         |  Milestone:  Awaiting Review
Component:  Network Admin  |    Version:  3.6.1
 Severity:  minor          |   Keywords:
---------------------------+-----------------------------
 "Warning: constant(): Couldn't find constant SUNRISE in
 C:\xampp\htdocs\wpnet\wp-admin\includes\class-wp-plugins-list-table.php on
 line 324"
 is displayed on /wp-admin/network/plugins.php?plugin_status=dropins when a
 Drop-in is present in /wp-content/ but wp-config.php does not DEFINE its
 constant.

 Suggested resolution:

 Prefix constant() function with @ in line 324 of /wp-admin/includes/class-
 wp-plugins-list-table.php as shown:
 {{{
 } elseif ( @constant( $dropins[ $plugin_file ][1] ) ) { // Constant is
 true
 }}}

--
Ticket URL: <http://core.trac.wordpress.org/ticket/25301>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list