Make WordPress Core


Ignore:
Timestamp:
06/26/2020 06:47:28 PM (6 years ago)
Author:
SergeyBiryukov
Message:

Docs: Standardize on "Returning a value from the filter" vs. "Passing a value to the filter".

The filter is the callback function added with add_filter(), therefore the hook passes a value to the filter, and the filter returns a value to change its behaviour.

The documentation is referring to the latter.

Props johnbillion.
See #49572, #16557.

File:
1 edited

Legend:

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

    r48184 r48185  
    881881     * Filters whether to short-circuit moving the uploaded file after passing all checks.
    882882     *
    883      * If a non-null value is passed to the filter, moving the file and any related error
    884      * reporting will be completely skipped.
     883     * If a non-null value is returned from the filter, moving the file and any related
     884     * error reporting will be completely skipped.
    885885     *
    886886     * @since 4.9.0
Note: See TracChangeset for help on using the changeset viewer.