[wp-trac] [WordPress Trac] #41683: Add Widget REST API endpoint

WordPress Trac noreply at wordpress.org
Tue May 25 09:07:14 UTC 2021


#41683: Add Widget REST API endpoint
--------------------------------------+-------------------------
 Reporter:  spacedmonkey              |       Owner:  noisysocks
     Type:  feature request           |      Status:  reopened
 Priority:  normal                    |   Milestone:  5.8
Component:  REST API                  |     Version:  4.7
 Severity:  normal                    |  Resolution:
 Keywords:  has-patch has-unit-tests  |     Focuses:  rest-api
--------------------------------------+-------------------------
Changes (by SergeyBiryukov):

 * status:  closed => reopened
 * resolution:  fixed =>


Comment:

 Per the [https://developer.wordpress.org/coding-standards/inline-
 documentation-standards/php/#other-tags WordPress Documentation
 Standards]:
 > **@author Tag**
 >
 > It is WordPress’ policy not to use the `@author` tag, except in the case
 of maintaining it in external libraries. We do not want to imply any sort
 of “ownership” over code that might discourage contribution.
 >
 > **@copyright and @license Tags**
 >
 > The `@copyright` and `@license` tags are used in external libraries and
 scripts, and should not be used in WordPress core files.
 >
 > `@copyright` is used to specify external script copyrights.
 > `@license` is used to specify external script licenses.

 Based on the above, would `rest-api/endpoints/class-wp-rest-sidebars-
 controller.php` still be maintained as an external library or a core file
 from now on? If the latter, then I guess this whole fragment should be
 removed from   `WP_REST_Sidebars_Controller` for consistency with other
 REST API classes:
 {{{
  * Copyright (C) 2015  Martin Pettersson
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation, either version 3 of the License, or
  * (at your option) any later version.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  *
  * @author    Martin Pettersson <martin_pettersson at outlook.com>
  * @copyright 2015 Martin Pettersson
  * @license   GPLv2
  * @link      https://github.com/martin-pettersson/wp-rest-api-sidebars
 }}}

 To keep the original author's credit, it could be replaced with a comment
 like the one we have in the `wpdb` class:
 {{{
 Original code from {@link http://php.justinvincent.com Justin Vincent
 (justin at visunet.ie)}
 }}}

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


More information about the wp-trac mailing list