Skip to content

Commit 66b790e

Browse files
committed
Make work with Ruby 3.2
File:Class seems to have dropped "exists?" Signed-off-by: Sven Strickroth <[email protected]>
1 parent 547c199 commit 66b790e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/jekyll-multisite.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ def sanitized_path(base_directory, questionable_path)
3434
base_directory
3535
elsif questionable_path.start_with?(base_directory)
3636
questionable_path
37-
elsif File.exists?(questionable_path) and !questionable_path.start_with?('/') and (ENV['OS'] == 'Windows_NT')
37+
elsif File.exist?(questionable_path) and !questionable_path.start_with?('/') and (ENV['OS'] == 'Windows_NT')
3838
File.expand_path(questionable_path)
39-
elsif File.exists?(questionable_path) and questionable_path != '/' and !(ENV['OS'] == 'Windows_NT')
39+
elsif File.exist?(questionable_path) and questionable_path != '/' and !(ENV['OS'] == 'Windows_NT')
4040
File.expand_path(questionable_path)
4141
else
4242
File.join(base_directory, questionable_path)
@@ -91,7 +91,7 @@ def self.sync_dir(cur, base, dest)
9191
if File.basename(f) == '.' or File.basename(f) == '..'
9292
next
9393
elsif File.directory?(f)
94-
if not File.exists?(dest_dir)
94+
if not File.exist?(dest_dir)
9595
Dir.mkdir(dest_dir)
9696
end
9797
sync_dir(f, base, dest)

0 commit comments

Comments
 (0)