Exclude conference model from ClassLength cop

Exclude conference.rb file from ClassLength Rubocop cop and decrease the
max value of this cop to 300, as the following class in number of lines is
event.rb with 218.

Also, remove unused comments from Conference model class.
This commit is contained in:
Ana María Martínez Gómez
2016-12-21 11:42:19 +01:00
parent bde2ee3d7d
commit ebb5203887
2 changed files with 3 additions and 5 deletions

View File

@@ -95,7 +95,9 @@ Metrics/BlockNesting:
Max: 4
Metrics/ClassLength:
Max: 575
Max: 300
Exclude:
- 'app/models/conference.rb'
# avoid redundunt curly braces when it is obvious that hash is used
Style/BracesAroundHashParameters:

View File

@@ -1,6 +1,3 @@
# rubocop:disable Metrics/ClassLength
##
# This class represents a conference
class Conference < ActiveRecord::Base
require 'uri'
serialize :events_per_week, Hash
@@ -1081,4 +1078,3 @@ class Conference < ActiveRecord::Base
result
end
end
# rubocop:enable Metrics/ClassLength