[wp-trac] [WordPress Trac] #29583: The getter in WP_Error may cause an "Undefined property" notice

WordPress Trac noreply at wordpress.org
Wed Sep 17 15:46:49 UTC 2014


#29583: The getter in WP_Error may cause an "Undefined property" notice
---------------------------+------------------
 Reporter:  bjornjohansen  |       Owner:
     Type:  defect (bug)   |      Status:  new
 Priority:  normal         |   Milestone:  4.1
Component:  General        |     Version:  4.0
 Severity:  normal         |  Resolution:
 Keywords:  has-patch      |     Focuses:
---------------------------+------------------

Comment (by BrianLayman):

 I'm getting these notices too. It seems there are two issues here - one
 the overall handling of get calls on properties that don't exist and
 second the code that calls these things..

 I'd propose that these are handled as two separate tickets.  Clearing the
 notice does not need to be bogged down in the debate about how to handle
 the version check.  I think serge's and Jeremy's code should be split off
 to another ticket.

 NOTE: My original code returned a false. I've modified to make it match
 the null in bjorn's code. Null is probably correct, but TBH I'd have to
 test the exact code to be fully satisfied of which the notice producing
 code originally returned.

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


More information about the wp-trac mailing list