[wp-trac] [WordPress Trac] #27754: Add ability to filter WP_Upgrader packages before upgrade
WordPress Trac
noreply at wordpress.org
Fri Apr 11 11:55:00 UTC 2014
#27754: Add ability to filter WP_Upgrader packages before upgrade
-----------------------------+-----------------------------
Reporter: nofearinc | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Upgrade/Install | Version: 3.8
Severity: normal | Keywords: has-patch
Focuses: |
-----------------------------+-----------------------------
Although #22378 adds a `upgrader_pre_download` filter which allows for
denying a package for an update, there are cases where we would need to
filter the package options or even trigger the `upgrader_pre_download`
filter based on other arguments before that.
A good example would be changing the destination to a local file or an
internal repository (like a CDN for plugins) for an internal network for
bandwidth or speed purposes.
I'm adding a sample `upgrader_package_options` filter right before
extracting the options in the `run()` function which is the central point
and the last step in the stack for this after calling functions like
install() or upgrade() have been fired from different places.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/27754>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list