[wp-trac] [WordPress Trac] #50075: Trigger _doing_it_wrong for dangerous REST API endpoint option

WordPress Trac noreply at wordpress.org
Mon May 4 14:41:13 UTC 2020


#50075: Trigger _doing_it_wrong for dangerous REST API endpoint option
--------------------------+-----------------------------
 Reporter:  rmccue        |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  REST API      |    Version:
 Severity:  normal        |   Keywords:  needs-patch
  Focuses:                |
--------------------------+-----------------------------
 REST API endpoints can be registered with a `permission_callback` option.
 It's really easy to accidentally write `permissions_callback` instead, and
 tough to catch during peer review, making this a potential footgun.

 We should trigger a `_doing_it_wrong()` for this.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/50075>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list