mirror of
https://github.com/getgrav/grav-plugin-admin.git
synced 2025-11-02 03:16:11 +01:00
Merge branch 'develop' of github.com:getgrav/grav-plugin-admin into 1.10
Conflicts: admin.php classes/plugin/AdminController.php composer.lock vendor/composer/autoload_classmap.php vendor/composer/autoload_psr4.php vendor/composer/autoload_real.php vendor/composer/autoload_static.php vendor/composer/installed.json
This commit is contained in:
@@ -920,11 +920,11 @@ class AdminBaseController
|
||||
$uri = $this->grav['uri'];
|
||||
$blueprint = base64_decode($uri->param('blueprint'));
|
||||
$path = base64_decode($uri->param('path'));
|
||||
$filename = basename($this->post['filename'] ?? '');
|
||||
$proute = base64_decode($uri->param('proute'));
|
||||
$route = base64_decode($uri->param('proute'));
|
||||
$type = $uri->param('type');
|
||||
$field = $uri->param('field');
|
||||
|
||||
$filename = basename($this->post['filename'] ?? '');
|
||||
if ($filename === '') {
|
||||
$this->admin->json_response = [
|
||||
'status' => 'error',
|
||||
@@ -936,7 +936,7 @@ class AdminBaseController
|
||||
|
||||
// Get Blueprint
|
||||
if ($type === 'pages' || strpos($blueprint, 'pages/') === 0) {
|
||||
$page = $this->admin->page(true, $proute);
|
||||
$page = $this->admin->page(true, $route);
|
||||
if (!$page) {
|
||||
$this->admin->json_response = [
|
||||
'status' => 'error',
|
||||
@@ -1052,10 +1052,7 @@ class AdminBaseController
|
||||
}
|
||||
|
||||
if (null === $filename) {
|
||||
$filename = base64_decode($this->grav['uri']->param('route'));
|
||||
if (!$filename) {
|
||||
$filename = base64_decode($this->route);
|
||||
}
|
||||
throw new \RuntimeException('Admin task RemoveMedia has been disabled.');
|
||||
}
|
||||
|
||||
$file = File::instance($filename);
|
||||
|
||||
Reference in New Issue
Block a user