Skip to content

Commit d718bcf

Browse files
Merge pull request #776 from puppetlabs/MAINT-Addressing_incorrect_targetrubyversion
(MAINT) Addressing wrong Rubocop TargetRubyVersion
2 parents 7d9fd72 + cbd8983 commit d718bcf

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.rubocop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ require:
77
AllCops:
88
DisplayCopNames: true
99
NewCops: enable
10-
TargetRubyVersion: '2.7'
10+
TargetRubyVersion: '2.6'
1111
ExtraDetails: true
1212
DisplayStyleGuide: true
1313
Include:

lib/puppet/type/concat_file.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,14 +190,14 @@ def exists?
190190

191191
def fragments
192192
# Collect fragments that target this resource by path, title or tag.
193-
@fragments ||= catalog.resources.filter_map do |resource|
193+
@fragments ||= catalog.resources.map { |resource|
194194
next unless resource.is_a?(Puppet::Type.type(:concat_fragment))
195195

196196
if resource[:target] == self[:path] || resource[:target] == title ||
197197
(resource[:tag] && resource[:tag] == self[:tag])
198198
resource
199199
end
200-
end
200+
}.compact
201201
end
202202

203203
def decompound(d)

0 commit comments

Comments
 (0)