[wp-trac] [WordPress Trac] #44901: Die earlier if confirm_key missing, no need to execute wp_validate_user_request_key

WordPress Trac noreply at wordpress.org
Wed Sep 5 22:21:08 UTC 2018


#44901: Die earlier if confirm_key missing, no need to execute
wp_validate_user_request_key
-----------------------------+------------------------------
 Reporter:  garrett-eclipse  |       Owner:  (none)
     Type:  enhancement      |      Status:  new
 Priority:  normal           |   Milestone:  Awaiting Review
Component:  Privacy          |     Version:  4.9.6
 Severity:  normal           |  Resolution:
 Keywords:                   |     Focuses:
-----------------------------+------------------------------

Comment (by garrett-eclipse):

 Thanks @birgire

 You're right that's my bad, my initial intentions was to avoid the extra
 WP_Error object that wasn't needed. But then thought the change would be
 better accepted if it was also avoiding the other function call but I
 guess it already did and I just rushed the description.

 So mostly aside from the readability is dropping the need for the extra
 WP_Error object if the confirm_key doesn't exist.

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


More information about the wp-trac mailing list