From 5df737b7e8bb8843c55957a2aa036b3970059029 Mon Sep 17 00:00:00 2001 From: "yuuji.yaginuma" Date: Wed, 9 Jan 2019 12:00:08 +0900 Subject: Enable `Lint/DeprecatedClassMethods` cop to avoid using deprecated methods --- actiontext/lib/templates/installer.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'actiontext/lib') diff --git a/actiontext/lib/templates/installer.rb b/actiontext/lib/templates/installer.rb index ee5a5af75b..dc549a8af3 100644 --- a/actiontext/lib/templates/installer.rb +++ b/actiontext/lib/templates/installer.rb @@ -14,7 +14,7 @@ run "yarn add https://github.com/rails/actiontext" APPLICATION_PACK_PATH = "app/javascript/packs/application.js" -if File.exists?(APPLICATION_PACK_PATH) && File.read(APPLICATION_PACK_PATH) !~ /import "actiontext"/ +if File.exist?(APPLICATION_PACK_PATH) && File.read(APPLICATION_PACK_PATH) !~ /import "actiontext"/ say "Adding import to default JavaScript pack" append_to_file APPLICATION_PACK_PATH, <<-EOS import "actiontext" -- cgit v1.2.3