upgrader_clear_destination WordPress Filter Hook

The upgrader_clear_destination hook is called when the destination folder for an upgrade is cleared. This hook allows you to take any necessary actions before the destination folder is cleared. For example, you may want to save any custom data or files that are in the folder before it is deleted.

apply_filters( 'upgrader_clear_destination', true|WP_Error $removed, string $local_destination, string $remote_destination, array $hook_extra ) #

Filters whether the upgrader cleared the destination.


Parameters

$removed

(true|WP_Error)Whether the destination was cleared. True upon success, WP_Error on failure.

$local_destination

(string)The local package destination.

$remote_destination

(string)The remote package destination.

$hook_extra

(array)Extra arguments passed to hooked filters.


Top ↑

Source

File: wp-admin/includes/class-wp-upgrader.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
2.8.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.