Replace deprecated File.exists?
File.exists? was deprecated in Ruby 2.1 and was removed in Ruby 3.2, in
favor of File.exist? .
Change-Id: I16b3a33e2838a56326ec7110916727a19e3e78da
(cherry picked from commit 3792ec0aa2
)
This commit is contained in:
@@ -118,7 +118,7 @@ Puppet::Type.type(:vs_port).provide(
|
|||||||
|
|
||||||
def bonding?
|
def bonding?
|
||||||
# To do: replace with iproute2 commands
|
# To do: replace with iproute2 commands
|
||||||
if File.exists?("/proc/net/bonding/#{@resource[:port]}")
|
if File.exist?("/proc/net/bonding/#{@resource[:port]}")
|
||||||
return true
|
return true
|
||||||
else
|
else
|
||||||
return false
|
return false
|
||||||
|
Reference in New Issue
Block a user