We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9c5e5ce commit f2b193dCopy full SHA for f2b193d
lib/puppet/provider/postgresql_conf/ruby.rb
@@ -19,8 +19,7 @@ def parse_config
19
active_settings = []
20
# iterate the file and construct a hash for every matching/active setting
21
# the hash is pushed to the array and the array is returned
22
- File.foreach(resource[:target]).with_index do |line, index|
23
- line_number = index + 1
+ File.foreach(resource[:target]).with_index(1) do |line, line_number|
24
matches = line.match(active_values_regex)
25
if matches
26
value = if matches[:value].to_i.to_s == matches[:value]
0 commit comments