Merge pull request #1186 from bf4/empty_else

Enforce case requires else; allow else nil
This commit is contained in:
Lucas Hosseini 2015-09-21 17:48:27 +02:00
commit 35473cf983
2 changed files with 9 additions and 0 deletions

View File

@ -45,6 +45,13 @@ Style/ClassAndModuleChildren:
Style/Documentation:
Enabled: false
Style/MissingElse:
Enabled: true
EnforcedStyle: case
Style/EmptyElse:
EnforcedStyle: empty
Style/MultilineOperationIndentation:
EnforcedStyle: indented

View File

@ -102,6 +102,8 @@ module ActiveModel
self.class.new(@hash[:*])
when @hash.key?(:**)
self.class.new(:** => {})
else
nil
end
end
end