From 5cde9a21ec51555c199127c7968893c95e4d20dd Mon Sep 17 00:00:00 2001 From: Kevin De Pelseneer Date: Tue, 25 Jun 2024 10:55:01 +0200 Subject: [PATCH] Fix typo FileUtils doesn't have a `delete` method. Instead used `rm_f`. --- app/controllers/templates_controller.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/controllers/templates_controller.rb b/app/controllers/templates_controller.rb index b099d8bdda..921d1fc863 100644 --- a/app/controllers/templates_controller.rb +++ b/app/controllers/templates_controller.rb @@ -94,7 +94,7 @@ def populate_template dir = Seek::Config.append_filestore_path('source_types') if Dir.exist?(dir) - FileUtils.delete(Dir.glob("#{dir}/*")) + FileUtils.rm_f(Dir.glob("#{dir}/*")) else FileUtils.mkdir_p(dir) end @@ -172,7 +172,7 @@ def set_status elsif File.exist?(resultfile) res = File.read(resultfile) @status = res - FileUtils.delete(resultfile) + FileUtils.rm_f(resultfile) else @status = 'not_started' end @@ -192,7 +192,7 @@ def running! end def done! - FileUtils.delete(lockfile) + FileUtils.rm_f(lockfile) end def running?