#34415 closed enhancement (fixed)
Force disable WP-API 2.0-beta4 and below
| Reported by: | danielbachhuber | Owned by: | dd32 |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.4 |
| Component: | REST API | Version: | |
| Severity: | normal | Keywords: | has-patch |
| Cc: | Focuses: |
Description
Because WP-API 2.0-beta4 and below versions aren't compatible with WP 4.4, we need to force disable these versions of the plugin on upgrade.
Slack conversation: https://wordpress.slack.com/archives/core-restapi/p1445529134000413
Attachments (2)
Change History (7)
#2
@
11 years ago
The deactivation will need to occur within wp-admin/includes/update-core.php, see this blog post of mine for a way of testing those changes.
Reasoning: That file is included into the current state of WordPress which then updates it to the new files.
#3
@
11 years ago
- Keywords has-patch added; needs-patch removed
- Owner set to
- Status new → assigned
34415.diff gets the ball rolling on update-core.php
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Theoretically, deactivating the plugin would be as simple as this (inside
upgrade_440()):However, I just installed a previous beta on a local 4.3 site, updated it to trunk and immediately got a fatal error.
Deactivation needs to happen earlier, e.g. in
wp_get_active_and_valid_plugins(), as can be seen in the attached proof-of-concept. I don't really like that method though.