aboutsummaryrefslogtreecommitdiffstats
path: root/admin/include
diff options
context:
space:
mode:
authorz0rglub <z0rglub@piwigo.org>2003-10-04 17:13:19 +0000
committerz0rglub <z0rglub@piwigo.org>2003-10-04 17:13:19 +0000
commit6d0112b562ead68210b1ac1d27a4db0129c71aea (patch)
tree3695cfdb25d46beb507e1d5d75deeda5f605bc0f /admin/include
parent151dc433708d67dad6e8e4b78a30dd52642394af (diff)
Bug in the deletion of favorites : even if the category was authorized, the
favorites where deleted for the user git-svn-id: http://piwigo.org/svn/trunk@167 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--admin/include/functions.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/admin/include/functions.php b/admin/include/functions.php
index 0f35c2798..22361a579 100644
--- a/admin/include/functions.php
+++ b/admin/include/functions.php
@@ -279,7 +279,7 @@ function check_favorites( $user_id )
{
array_push( $picture_cat, $picture_row['category_id'] );
}
- if ( count( array_diff( $picture_cat, $restricted_cat ) ) > 0 )
+ if ( count( array_diff( $picture_cat, $restricted_cat ) ) == 0 )
{
$query = 'DELETE FROM '.PREFIX_TABLE.'favorites';
$query.= ' WHERE image_id = '.$row['image_id'];