From 011cd724ed04db4b519363fbdae4f7fd526dea51 Mon Sep 17 00:00:00 2001 From: Masataka Pocke Kuwabara Date: Mon, 14 Mar 2022 13:54:10 +0900 Subject: [PATCH] Replace deprecated `File.exists?` with `exist?` for Ruby script --- .rubygems/bin/lefthook | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.rubygems/bin/lefthook b/.rubygems/bin/lefthook index b1fcbb99..c9fba64f 100755 --- a/.rubygems/bin/lefthook +++ b/.rubygems/bin/lefthook @@ -26,7 +26,7 @@ binary = "#{binary}.exe" if os == "windows" args = $*.map { |x| x.include?(' ') ? "'" + x + "'" : x } cmd = File.expand_path "#{File.dirname(__FILE__)}/../libexec/#{binary}" -unless File.exists?(cmd) +unless File.exist?(cmd) raise "Invalid platform. Lefthook wasn't build for #{RUBY_PLATFORM}" end