summaryrefslogtreecommitdiffstats
path: root/application/controllers
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2013-08-29 17:57:09 +0200
committerFlorian Pritz <bluewind@xinu.at>2013-09-02 22:02:27 +0200
commit39eacae51f4fbc239a11b150b752a76bccf74445 (patch)
tree9532d2c643f9405542a5a778ddb8294f8c06fb89 /application/controllers
parentb88bdf6727a91451450a066f37e865e3b1b5a60d (diff)
claim_id: Fix error when called directly without last_upload data
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'application/controllers')
-rw-r--r--application/controllers/file.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/application/controllers/file.php b/application/controllers/file.php
index 992252ff5..6e660b306 100644
--- a/application/controllers/file.php
+++ b/application/controllers/file.php
@@ -704,9 +704,16 @@ class File extends MY_Controller {
$this->muser->require_access();
$last_upload = $this->session->userdata("last_upload");
+
+ if ($last_upload === false) {
+ show_error("Failed to get last upload data");
+ }
+
$ids = $last_upload["ids"];
$errors = array();
+ assert(is_array($ids));
+
foreach ($ids as $key => $id) {
$filedata = $this->mfile->get_filedata($id);