From f3219ada148505d3f6f7a4acdf3376d80576b3bb Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Tue, 12 May 2020 19:18:45 +0100 Subject: [PATCH] Fix new rubocop warnings --- app/controllers/application_controller.rb | 1 + lib/classic_pagination/pagination.rb | 1 + 2 files changed, 2 insertions(+) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index f419460ee..009984594 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -10,6 +10,7 @@ class ApplicationController < ActionController::Base around_action :better_errors_allow_inline, :if => proc { Rails.env.development? } attr_accessor :current_user + helper_method :current_user private diff --git a/lib/classic_pagination/pagination.rb b/lib/classic_pagination/pagination.rb index dbeaf5a40..b435a7111 100644 --- a/lib/classic_pagination/pagination.rb +++ b/lib/classic_pagination/pagination.rb @@ -309,6 +309,7 @@ module ActionController @number = 1 unless @paginator.has_page_number? @number end attr_reader :paginator, :number + alias to_i number # Compares two Page objects and returns true when they represent the -- 2.39.5