Ejemplo n.º 1
0
 public function getPrevPhotoIdList($listType, $photoId)
 {
     if (in_array($listType, array('albumPhotos', 'userPhotos'))) {
         $ownerId = $this->findPhotoOwner($photoId);
         $checkPrivacy = $this->isCheckPrivacy($ownerId);
     } else {
         $checkPrivacy = FALSE;
     }
     if (in_array($listType, array('toprated', 'most_discussed'))) {
         switch ($listType) {
             case 'toprated':
                 return $this->getTopratedPhotoIdList();
             case 'most_discussed':
                 return $this->getMostDiscussedPhotoIdList();
         }
     }
     return $this->photoDao->getPrevPhotoIdList($listType, $photoId, $checkPrivacy);
 }