class ModerateController < ApplicationController

  before_action :authenticate_user!

#   def index
#     # First package with pending screenshots
#     @package = Package.joins(:screenshots).where('screenshots.approved=false').distinct(:name).first

#     if @package
#       # List of screenshots to be moderated
#       @pending_screenshots = @package.screenshots_pending
#       # Number of screenshots that were already moderated (during this session)
#       session[:already_moderated] ||= 0
#       @moderated_screenshots = session[:already_moderated]

#       # BUG: calculation is wrong when pending and reported screenshots are in the queue
#       # Percentage of already moderated screenshots
#       @percent_moderated = 100 * (@moderated_screenshots+1) / (@moderated_screenshots + @pending_screenshots.count)
#       # @percent_moderated = 100 * (@moderated_screenshots+1) / (@moderated_screenshots + @pending_screenshots.count + @reported_screenshots.count)
#     end
#   end
end
