lib/rubocop/cop/severity.rb in rubocop-0.58.2 vs lib/rubocop/cop/severity.rb in rubocop-0.59.0
- old
+ new
@@ -32,9 +32,10 @@
def initialize(name_or_code)
name = Severity.name_from_code(name_or_code)
unless NAMES.include?(name)
raise ArgumentError, "Unknown severity: #{name}"
end
+
@name = name.freeze
freeze
end
# @api private