aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/admin_controller.rb
diff options
context:
space:
mode:
authorLouise Crow <louise.crow@gmail.com>2012-12-13 20:39:33 +0000
committerLouise Crow <louise.crow@gmail.com>2012-12-13 20:39:33 +0000
commitb446bbee9d936f3f5424f4c79b34577416a68f7f (patch)
tree20dcd9a64554816fdb4765be7a776592aa926814 /app/controllers/admin_controller.rb
parentfed1571d319023d93287c98b1a155cbd75aec8b6 (diff)
parenta5744b206cf1ca811f913d68cafc0178079be2f7 (diff)
Merge branch 'hotfix/authenticate-and-expire-download-zips' into wdtk
Diffstat (limited to 'app/controllers/admin_controller.rb')
-rw-r--r--app/controllers/admin_controller.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/controllers/admin_controller.rb b/app/controllers/admin_controller.rb
index d7933b212..d93e68dab 100644
--- a/app/controllers/admin_controller.rb
+++ b/app/controllers/admin_controller.rb
@@ -28,6 +28,10 @@ class AdminController < ApplicationController
cache_subpath = foi_fragment_cache_all_for_request(info_request)
FileUtils.rm_rf(cache_subpath)
+ # Remove any download zips
+ download_dir = request_download_zip_dir(info_request)
+ FileUtils.rm_rf(download_dir)
+
# Remove the database caches of body / attachment text (the attachment text
# one is after privacy rules are applied)
info_request.clear_in_database_caches!