Skip to content

Commit

Permalink
fix rubocop linting
Browse files Browse the repository at this point in the history
  • Loading branch information
C24-AK committed Jun 5, 2024
1 parent 81f8c25 commit 7cf05de
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions lib/facter/vault_version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
# Purpose: Retrieve vault version if installed
#
Facter.add(:vault_version) do
setcode do
if Facter::Util::Resolution.which('vault')
vault_server_version_output = Facter::Util::Resolution.exec('vault version')
match = vault_server_version_output.match(%r{Vault v(\d+\.\d+\.\d+)})
match&.captures.first
end
setcode do
if Facter::Util::Resolution.which('vault')
vault_server_version_output = Facter::Util::Resolution.exec('vault version')
match = vault_server_version_output.match(%r{Vault v(\d+\.\d+\.\d+)})
match&.captures&.first
end
end
end

0 comments on commit 7cf05de

Please sign in to comment.