[trunk] - feature:2961 Thanks to msakik for report

git-svn-id: http://piwigo.org/svn/trunk@24525 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
ddtddt
2013-09-18 21:20:30 +00:00
parent d2149bcccf
commit fe8e2c9a06
+6 -4
View File
@@ -121,11 +121,8 @@ DELETE
if ('del_tags' == $action)
{
if (count($_POST['del_tags']) == 0)
if (isset($_POST['del_tags']) and count($_POST['del_tags']) > 0)
{
array_push($page['errors'], l10n('Select at least one tag'));
}
$query = '
DELETE
FROM '.IMAGE_TAG_TABLE.'
@@ -133,6 +130,11 @@ DELETE
AND tag_id IN ('.implode(',', $_POST['del_tags']).')
;';
pwg_query($query);
}
else
{
array_push($page['errors'], l10n('Select at least one tag'));
}
}
if ('associate' == $action)