Skip to content

Commit 62c2ef1

Browse files
committed
Lint/FormatParameterMismatch
1 parent fa8352e commit 62c2ef1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/puppet/resource.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -453,10 +453,12 @@ def to_hierayaml
453453
attr.unshift(:ensure)
454454
end
455455

456+
# rubocop:disable Lint/FormatParameterMismatch
456457
attributes = attr.collect { |k|
457458
v = parameters[k]
458459
" %-#{attr_max}s: %s\n" % [k, Puppet::Parameter.format_value_for_display(v)]
459460
}.join
461+
# rubocop:enable Lint/FormatParameterMismatch
460462

461463
" %s:\n%s" % [self.title, attributes]
462464
end
@@ -488,10 +490,12 @@ def to_manifest
488490
attr.unshift(:ensure)
489491
end
490492

493+
# rubocop:disable Lint/FormatParameterMismatch
491494
attributes = attr.collect { |k|
492495
v = parameters[k]
493496
" %-#{attr_max}s => %s,\n" % [k, Puppet::Parameter.format_value_for_display(v)]
494497
}.join
498+
# rubocop:enable Lint/FormatParameterMismatch
495499

496500
escaped = self.title.gsub(/'/, "\\\\'")
497501
"%s { '%s':\n%s}" % [self.type.to_s.downcase, escaped, attributes]

0 commit comments

Comments
 (0)