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?