rawurlencode( $name ), 'plugin_status' => 'inactive', ], admin_url( 'plugins.php' ) ); } /** * The installed plugins, keyed by file. * * `get_plugins()` lives in an admin include that is not always loaded, and * it scans the plugins directory, so the result is held for the request. * * @since 1.4.0 * * @return array> */ private static function installed(): array { static $plugins = null; if ( $plugins !== null ) { return $plugins; } if ( ! function_exists( 'get_plugins' ) ) { require_once ABSPATH . 'wp-admin/includes/plugin.php'; } $plugins = get_plugins(); return $plugins; } }