Skip to content
This repository has been archived by the owner on Feb 22, 2022. It is now read-only.

Self-deactivate the plugin after the functionality has been merged to core #123

Merged
merged 4 commits into from
May 13, 2020

Conversation

azaozz
Copy link
Contributor

@azaozz azaozz commented May 10, 2020

This will depend on where the functions are added in core.

If they are in wp-admin/includes/*, they are loaded after plugins are loaded, so the plugin cannot check if they exist before loading. In this case the function names from the plugin cannot be reused for core (results in fatal error). Adding the two or three functions to wp-admin/includes/update.php seems to make sense. The current code in this PR is for this case.

If they are in wp-includes/* the existing method would work. The check whether plugins and themes auto-updating is (globally) enabled may be in wp-includes/update.php.

In both of the above cases some updates to the code in wp-autoupdates.php would be needed.

@azaozz
Copy link
Contributor Author

azaozz commented May 11, 2020

Just a note that this is not ready for merging. The changes will need update and review after the core patch is ready (the new core function's places and names are known).

@pbiron pbiron marked this pull request as draft May 11, 2020 23:57
@pbiron
Copy link
Contributor

pbiron commented May 11, 2020

Just a note that this is not ready for merging. The changes will need update and review after the core patch is ready (the new core function's places and names are known).

Just marked this as Draft just to be safe.

@pbiron pbiron marked this pull request as ready for review May 13, 2020 20:16
@pbiron pbiron requested a review from audrasjb May 13, 2020 20:19
@pbiron
Copy link
Contributor

pbiron commented May 13, 2020

@azaozz this is now ready to review

@pbiron pbiron added this to the 0.8.0 milestone May 13, 2020
@azaozz
Copy link
Contributor Author

azaozz commented May 13, 2020

Looks good.

Copy link
Contributor

@audrasjb audrasjb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pbiron you removed wp_auto_update_uninstall function?

wp-autoupdates.php Outdated Show resolved Hide resolved
@pbiron pbiron requested a review from audrasjb May 13, 2020 21:30
Copy link
Contributor

@audrasjb audrasjb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants