Merge branch 'hotfix-2.2.17'

pull/274/merge
iglocska 2014-03-24 09:15:21 +01:00
commit a9774076b1
1 changed files with 1 additions and 2 deletions

View File

@ -1138,9 +1138,8 @@ class Attribute extends AppModel {
if ($type != 'md5' && $type != 'sha1') {
throw new UnauthorizedException('Invalid hash type.');
}
//restricting to non-private or same org if the user is not a site-admin.
$conditions['AND'] = array('Attribute.to_ids' => 1, 'Event.published' => 1);
$conditions['AND'] = array('Attribute.to_ids' => 1, 'Event.published' => 1, 'Attribute.type' => $type);
if (!$isSiteAdmin) {
$temp = array();
$distribution = array();