Make WordPress Core


Ignore:
Timestamp:
12/13/2022 04:37:36 PM (2 years ago)
Author:
johnbillion
Message:

Options, Meta APIs: Correct the documented return type for get_settings_errors().

This function returns an array of settings errors arrays.

Props mcaskill, costdev

Fixes #57323

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/template.php

    r54896 r54963  
    18471847 * @param string $setting  Optional. Slug title of a specific setting whose errors you want.
    18481848 * @param bool   $sanitize Optional. Whether to re-sanitize the setting value before returning errors.
    1849  * @return array {
    1850  *     Array of settings errors.
    1851  *
    1852  *     @type string $setting Slug title of the setting to which this error applies.
    1853  *     @type string $code    Slug-name to identify the error. Used as part of 'id' attribute in HTML output.
    1854  *     @type string $message The formatted message text to display to the user (will be shown inside styled
    1855  *                           `<div>` and `<p>` tags).
    1856  *     @type string $type    Optional. Message type, controls HTML class. Possible values include 'error',
    1857  *                           'success', 'warning', 'info'. Default 'error'.
     1849 * @return array[] {
     1850 *     Array of settings error arrays.
     1851 *
     1852 *     @type array ...$0 {
     1853 *         Associative array of setting error data.
     1854 *
     1855 *         @type string $setting Slug title of the setting to which this error applies.
     1856 *         @type string $code    Slug-name to identify the error. Used as part of 'id' attribute in HTML output.
     1857 *         @type string $message The formatted message text to display to the user (will be shown inside styled
     1858 *                               `<div>` and `<p>` tags).
     1859 *         @type string $type    Optional. Message type, controls HTML class. Possible values include 'error',
     1860 *                               'success', 'warning', 'info'. Default 'error'.
     1861 *     }
    18581862 * }
    18591863 */
Note: See TracChangeset for help on using the changeset viewer.