]> source.dussan.org Git - redmine.git/commitdiff
use "attr_writer" instead of "attr_accessor" for QueryColumn#sortable
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Mon, 7 Oct 2019 11:45:11 +0000 (11:45 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Mon, 7 Oct 2019 11:45:11 +0000 (11:45 +0000)
QueryColumn#sortable is already defined in this class.

git-svn-id: http://svn.redmine.org/redmine/trunk@18616 e93f8b46-1217-0410-a6f0-8f06a7374b81

.rubocop_todo.yml
app/models/query.rb

index cbaa842b87fa0e1d160738d06be71a8e33b30a17..2392983c2771eb29c634fadd67f07f83c94f0f7b 100644 (file)
@@ -495,7 +495,6 @@ Lint/DeprecatedClassMethods:
 
 Lint/DuplicateMethods:
   Exclude:
-    - 'app/models/query.rb'
     - 'app/models/wiki_page.rb'
 
 Lint/EmptyWhen:
index bd2b0c5c184688c79f1358f92a86538f19061f83..3b37a8dd031f15196049e8849cced14a6f7466e5 100644 (file)
@@ -20,7 +20,8 @@
 require 'redmine/sort_criteria'
 
 class QueryColumn
-  attr_accessor :name, :sortable, :groupable, :totalable, :default_order
+  attr_accessor :name, :groupable, :totalable, :default_order
+  attr_writer   :sortable
   include Redmine::I18n
 
   def initialize(name, options={})