From 3f32ee0ef6f499fb10cbaf4c3035d434dbdfbffc Mon Sep 17 00:00:00 2001 From: Marcin Kulik Date: Sun, 26 Apr 2015 13:54:23 +0000 Subject: [PATCH] No "self" needed here --- app/controllers/asciicasts_controller.rb | 1 - app/models/asciicast.rb | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/app/controllers/asciicasts_controller.rb b/app/controllers/asciicasts_controller.rb index 6f6fd58..3808706 100644 --- a/app/controllers/asciicasts_controller.rb +++ b/app/controllers/asciicasts_controller.rb @@ -15,7 +15,6 @@ class AsciicastsController < ApplicationController end def show - # TODO: filter out private or not (????) respond_to do |format| format.html do view_counter.increment(asciicast, cookies) diff --git a/app/models/asciicast.rb b/app/models/asciicast.rb index 96cf9f1..be772ea 100644 --- a/app/models/asciicast.rb +++ b/app/models/asciicast.rb @@ -48,7 +48,7 @@ class Asciicast < ActiveRecord::Base end def self.for_category_ordered(category, order, page = nil, per_page = nil) - collection = self.non_private + collection = non_private if category == :featured collection = collection.featured