Moved screenshots_visible_to_user to model

This commit is contained in:
Christoph Haas 2016-04-06 16:41:38 +02:00
parent 1cc189ccdc
commit ba5a89a26a
3 changed files with 12 additions and 13 deletions

View file

@ -4,8 +4,8 @@
.small-7.medium-7.columns.packagepage
p.subtitle = @package.description
- if @package.screenshots_visible_to_user.count > 0
- @package.screenshots_visible_to_user.each do |screenshot|
- if @package.screenshots_visible_to_user(session[:token]).count > 0
- @package.screenshots_visible_to_user(session[:token]).each do |screenshot|
.row.listview
.small-12.columns
.text-center