fix breaking change in ruby; exists? -> exist?

This commit is contained in:
Ward Wouts 2026-03-13 08:39:42 +01:00
parent 257c54ee18
commit 009e2fa561
5 changed files with 12 additions and 12 deletions

View file

@ -314,7 +314,7 @@ def fetch(uri_str, limit = 10)
raise ArgumentError, 'HTTP redirect too deep' if limit == 0
if URI.parse(uri_str).scheme.to_s == "file"
response = ""
if FileTest.exists?(URI.parse(uri_str).path)
if FileTest.exist?(URI.parse(uri_str).path)
File.open(URI.parse(uri_str).path).each_line{|line|
response += line
}
@ -667,7 +667,7 @@ if options["-H"]
# even controleren of er al een .svn dir staat op deze locatie
# entries en andere bestanden zijn read-only, dus de rest loopt er op
# stuk. Bovendien wil je het zeer waarschijnlijk niet. Echt niet.
if FileTest.exists?(".svn")
if FileTest.exist?(".svn")
STDERR.puts ".svn dir found at current location"
STDERR.puts "please use a different location"
exit