WordPress.org

Make WordPress Core


Ignore:
Timestamp:
08/07/2020 07:23:04 PM (4 months ago)
Author:
whyisjake
Message:

Docs: Correct usage of the dynamic auto_update_{$type} filter.

This ensures that the canonical name of the filter is used in Site Health debug data, as well as on plugin and theme screens, so the developer reference site remains correct.

This brings the changes from [48750] to the 5.5 branch.

Props johnbillion.
Fixes #50868, see [48750].

Location:
branches/5.5
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/5.5

  • branches/5.5/src/wp-admin/includes/theme.php

    r48698 r48756  
    717717        }
    718718
    719         /** This action is documented in wp-admin/includes/class-wp-automatic-updater.php */
    720         $auto_update_forced = apply_filters( 'auto_update_theme', null, $auto_update_filter_payload );
     719        $type = 'theme';
     720        /** This filter is documented in wp-admin/includes/class-wp-automatic-updater.php */
     721        $auto_update_forced = apply_filters( "auto_update_{$type}", null, $auto_update_filter_payload );
    721722
    722723        $prepared_themes[ $slug ] = array(
Note: See TracChangeset for help on using the changeset viewer.