summaryrefslogtreecommitdiffstats
path: root/application/service
diff options
context:
space:
mode:
Diffstat (limited to 'application/service')
-rw-r--r--application/service/files.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/application/service/files.php b/application/service/files.php
index b4bf7b9ee..8d0760b87 100644
--- a/application/service/files.php
+++ b/application/service/files.php
@@ -14,12 +14,16 @@ class files {
static public function history($user)
{
$CI =& get_instance();
+ $items = array();
$fields = array("id", "filename", "mimetype", "date", "hash", "filesize");
- $items = $CI->db->select(implode(',', $fields))
+ $query = $CI->db->select(implode(',', $fields))
->from('files')
->where('user', $user)
->get()->result_array();
+ foreach ($query as $key => $item) {
+ $items[$item["id"]] = $item;
+ }
$total_size = $CI->db->query("
SELECT sum(filesize) sum