Snapshot synced v3.6.1 working state as baseline
Machine-sync snapshot: the working tree carried the full 3.0.0-3.6.1 arc (licensing/FileManager/DatabaseExplorer removal, all new replacement screens and REST controllers) that had not been committed on this machine. Captured here as a safety baseline before starting the Adminify-parity revamp. Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
07d77bda57
commit
e2db2ad4b5
@@ -153,6 +153,16 @@ class PluginsData
|
||||
if (!function_exists("delete_plugins")) {
|
||||
require_once ABSPATH . "wp-admin/includes/plugin.php";
|
||||
}
|
||||
// delete_plugins() calls request_filesystem_credentials() internally
|
||||
// (WP_Filesystem setup) — that's defined in file.php, which a REST API
|
||||
// request doesn't load by default the way a normal wp-admin page load
|
||||
// does. Without this, deleting a plugin fataled with "Call to
|
||||
// undefined function request_filesystem_credentials()" instead of
|
||||
// actually deleting anything. update_plugin() below already required
|
||||
// this for the same reason; delete_plugin() just never got it.
|
||||
if (!function_exists("request_filesystem_credentials")) {
|
||||
require_once ABSPATH . "wp-admin/includes/file.php";
|
||||
}
|
||||
|
||||
$file = self::sanitize_file($request->get_param("file"));
|
||||
if (is_plugin_active($file)) {
|
||||
|
||||
Reference in New Issue
Block a user