From 0076a63cf2b07454ec37ff2c5f7bf2fd7e5e2c05 Mon Sep 17 00:00:00 2001 From: Julien Chanseaume Date: Wed, 30 Jul 2014 12:28:25 +0200 Subject: [PATCH] fixed issue to remove the summary, description or conclusion on an image or a document --- core/lib/Thelia/Controller/Admin/FileController.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/core/lib/Thelia/Controller/Admin/FileController.php b/core/lib/Thelia/Controller/Admin/FileController.php index c4f9401aa..a5cc4e7e1 100644 --- a/core/lib/Thelia/Controller/Admin/FileController.php +++ b/core/lib/Thelia/Controller/Admin/FileController.php @@ -358,21 +358,22 @@ class FileController extends BaseAdminController $file->setLocale($data['locale']); - if (isset($data['title'])) { + if (array_key_exists('title', $data)) { $file->setTitle($data['title']); } - if (isset($data['chapo'])) { + if (array_key_exists('chapo', $data)) { $file->setChapo($data['chapo']); } - if (isset($data['description'])) { + if (array_key_exists('description', $data)) { $file->setDescription($data['description']); } + if (array_key_exists('postscriptum', $data)) { + $file->setPostscriptum($data['postscriptum']); + } + if (isset($data['file'])) { $file->setFile($data['file']); } - if (isset($data['postscriptum'])) { - $file->setPostscriptum($data['postscriptum']); - } $event->setModel($file); $event->setOldModel($oldFile);