[wp-trac] [WordPress Trac] #49749: Bug in WordPress API when I have the prefix wp for the custom endpoint

WordPress Trac noreply at wordpress.org
Wed Apr 1 10:04:38 UTC 2020


#49749: Bug in WordPress API when I have the prefix wp for the custom endpoint
--------------------------+------------------------------
 Reporter:  skarabeq      |       Owner:  (none)
     Type:  defect (bug)  |      Status:  assigned
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  REST API      |     Version:  5.4
 Severity:  major         |  Resolution:
 Keywords:  needs-patch   |     Focuses:
--------------------------+------------------------------
Changes (by skarabeq):

 * severity:  normal => major


Comment:

 Yes, of course

 {{{#!php
 <?php
 $model = new Model;
 register_rest_route('/wp/v2', '/nav/' ,
     [
         [
             'methods'  => 'POST',
             'callback' => [$model, 'get_data'],
         ],
         'schema' => null,
     ]
 );
 }}}

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


More information about the wp-trac mailing list