Error found in Gallery v1.4.1 (Permissions view comments)

J.Scheffler

Joined: 2003-01-17
Posts: 8
Posted: Fri, 2004-01-30 09:51

If you change the permission for view comments you change the permissions for add comments.

The error was in the album_permissions.php

search for :

if (isset($allUid) && isset($submit_viewComments) && strchr($submit_viewComments, ">")) {
$gallery->album->setViewComments($allUid, 1);
$changed++;
} else if (isset($viewCommentsUid) && isset($submit_viewComments) && strchr($submit_viewComments, "<")) {
$gallery->album->setViewComments($addCommentsUid, 0);
$changed++;
}

Change to:

if (isset($allUid) && isset($submit_viewComments) && strchr($submit_viewComments, ">")) {
$gallery->album->setViewComments($allUid, 1);
$changed++;
} else if (isset($viewCommentsUid) && isset($submit_viewComments) && strchr($submit_viewComments, "<")) {
$gallery->album->setViewComments($setViewComments, 0);
$changed++;
}

That's all

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Fri, 2004-01-30 12:28

Hi,

thanks for reporting. This Bug is already fixed in CVS.
So 1.4.2-RC2 will contain the fix.

Regards,

Jens