From 1c78d41f46f71a32cde84841ab03eac13113b20e Mon Sep 17 00:00:00 2001 From: Cash Costello Date: Wed, 5 Jun 2013 20:20:59 -0400 Subject: Fixes #5601 allowing empty tags to pass through to clear previous tags --- mod/blog/actions/blog/save.php | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'mod/blog/actions') diff --git a/mod/blog/actions/blog/save.php b/mod/blog/actions/blog/save.php index 9256610cc..658f83580 100644 --- a/mod/blog/actions/blog/save.php +++ b/mod/blog/actions/blog/save.php @@ -79,11 +79,7 @@ foreach ($values as $name => $default) { switch ($name) { case 'tags': - if ($value) { - $values[$name] = string_to_tag_array($value); - } else { - unset ($values[$name]); - } + $values[$name] = string_to_tag_array($value); break; case 'excerpt': -- cgit v1.2.3 From 8dbdf2f72c9dccbbd471e805fbd112c6817cdcec Mon Sep 17 00:00:00 2001 From: Cash Costello Date: Wed, 5 Jun 2013 20:28:29 -0400 Subject: removed crazy code that doesn't do anything useful - only fires when $blog->foo = false --- mod/blog/actions/blog/save.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'mod/blog/actions') diff --git a/mod/blog/actions/blog/save.php b/mod/blog/actions/blog/save.php index 658f83580..82a9e6c51 100644 --- a/mod/blog/actions/blog/save.php +++ b/mod/blog/actions/blog/save.php @@ -121,10 +121,7 @@ if ($values['status'] == 'draft') { // assign values to the entity, stopping on error. if (!$error) { foreach ($values as $name => $value) { - if (FALSE === ($blog->$name = $value)) { - $error = elgg_echo('blog:error:cannot_save' . "$name=$value"); - break; - } + $blog->$name = $value; } } -- cgit v1.2.3