[wp-trac] [WordPress Trac] #52076: Checking anonymous user's exist capability returns inconsistent results across functions.

WordPress Trac noreply at wordpress.org
Thu Dec 24 02:37:13 UTC 2020


#52076: Checking anonymous user's exist capability returns inconsistent results
across functions.
-----------------------------+------------------------------
 Reporter:  peterwilsoncc    |       Owner:  (none)
     Type:  defect (bug)     |      Status:  new
 Priority:  normal           |   Milestone:  Awaiting Review
Component:  Role/Capability  |     Version:
 Severity:  normal           |  Resolution:
 Keywords:  early has-patch  |     Focuses:
-----------------------------+------------------------------

Comment (by peterwilsoncc):

 @johnbillion @johnjamesjacoby [https://github.com/WordPress/wordpress-
 develop/pull/841/files Draft pull request with POC is up].

 * Changes `user_can` to allow anonymous users to `exist`
 * `current_user_can()` becomes a wrapper of `user_can()`
 * `current_user_can_for_blog()` uses `current_user_can()` to determine if
 the user can.
 * capabilities group of tests is passing on both single and multisite test
 suite
 * leaving the full suite to run on GH.

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


More information about the wp-trac mailing list