diff options
author | vincent-peugnet <v.peugnet@free.fr> | 2020-04-25 17:53:44 +0200 |
---|---|---|
committer | vincent-peugnet <v.peugnet@free.fr> | 2020-04-25 17:53:44 +0200 |
commit | 0efeef6b6693d62675ec8a45e73c71f69e0a0362 (patch) | |
tree | 4b86b3bd62217fc4c60e2827e30a45209ce82605 /app/class/Controllermedia.php | |
parent | bd16dc7c6fc630a6b59ca3b041dde146ab50c72b (diff) | |
parent | 385b3f4adf86606e03941171c136d8f2eb2b35c2 (diff) | |
download | wcms-0efeef6b6693d62675ec8a45e73c71f69e0a0362.tar.gz wcms-0efeef6b6693d62675ec8a45e73c71f69e0a0362.zip |
Merge branch master with implement-exception
Diffstat (limited to 'app/class/Controllermedia.php')
-rw-r--r-- | app/class/Controllermedia.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/class/Controllermedia.php b/app/class/Controllermedia.php index 06885b3..95b4f9b 100644 --- a/app/class/Controllermedia.php +++ b/app/class/Controllermedia.php @@ -18,6 +18,9 @@ class Controllermedia extends Controller $this->mediamanager = new Modelmedia(); } + /** + * @throws Exception + */ public function desktop() { if ($this->user->iseditor()) { @@ -81,8 +84,9 @@ class Controllermedia extends Controller $dir = $_POST['dir'] ?? Model::MEDIA_DIR; $name = idclean($_POST['foldername']) ?? 'new-folder'; $this->mediamanager->adddir($dir, $name); + $this->redirect($this->generate('media') . '?path=/' . $dir . DIRECTORY_SEPARATOR . $name); } - $this->redirect($this->generate('media') . '?path=/' . $dir . DIRECTORY_SEPARATOR . $name); + $this->routedirect('home'); } public function folderdelete() |