From 15fcc900d3414afc1469361acd0e4d88efce96b4 Mon Sep 17 00:00:00 2001 From: Thomas Peterson Date: Thu, 18 Feb 2016 16:04:01 +0100 Subject: [PATCH] Optionen ohne Leere --- src/Article.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Article.php b/src/Article.php index f455844..7cdcf51 100644 --- a/src/Article.php +++ b/src/Article.php @@ -21,7 +21,7 @@ class Article } /** - * @param $params Array + * @param $params \Array */ public function setParams($params) { @@ -83,6 +83,9 @@ class Article $temp = array(); /** @var Option\Type\Base $option */ foreach ($this->options as $option) { + if($option->getValue() == '' && $option->getRawValue() == '') { + continue; + } $temp[$option->getId()] = array( 'name' => $option->getName(), 'value' => $option->getValue(),