Skip to content

Commit 99e21e2

Browse files
phumpalmajormoses
authored andcommitted
Rubocopped
1 parent e07866e commit 99e21e2

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

lib/sensu-plugins-postgres/pgpass.rb

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,8 @@
11
module Pgpass
22
def read_pgpass(pg_pass_file)
33
File.readlines(pg_pass_file).each do |line|
4-
if line.start_with?('#')
5-
# Perform no action. Line is a comment
6-
next
7-
else
8-
return line.strip.split(':')
9-
end
4+
return line.strip.split(':') unless line.start_with?('#')
5+
next
106
end
117
end
128

0 commit comments

Comments
 (0)