[wp-trac] [WordPress Trac] #35034: Handling undefined index notices in wp_old_slug_redirect

WordPress Trac noreply at wordpress.org
Sat Dec 12 13:17:36 UTC 2015


#35034: Handling undefined index notices in wp_old_slug_redirect
--------------------------+------------------------------
 Reporter:  nirajkvinit   |       Owner:
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Query         |     Version:
 Severity:  normal        |  Resolution:  invalid
 Keywords:                |     Focuses:
--------------------------+------------------------------
Changes (by nirajkvinit):

 * status:  new => closed
 * resolution:   => invalid


Comment:

 Replying to [comment:1 swissspidy]:
 > Under what circumstances are these values not set?
 >
 > Using `$wp_query->get( 'name' )` should suffice, as this function
 already does an `isset` check.

 You are correct! In my virtual pages, I faced this issue. Setting up query
 vars solved the issue! :p

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


More information about the wp-trac mailing list