Skip to content

Commit

Permalink
fix: revert back and skip cop for this. prsent is here a custom method
Browse files Browse the repository at this point in the history
Signed-off-by: Robert Waffen <[email protected]>
  • Loading branch information
rwaffen committed Sep 6, 2024
1 parent c71baf7 commit 7ae27d4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/models/hiera_data/layer.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
class HieraData
module Layer
def self.for(environment:, key: nil)
[Global.new, Environment.new(environment:), Module.new(environment:, key:)].compact_blank
# rubocop:disable Rails/CompactBlank
[Global.new, Environment.new(environment:), Module.new(environment:, key:)].select(&:present?)
# rubocop:enable Rails/CompactBlank
end
end
end

0 comments on commit 7ae27d4

Please sign in to comment.