summaryrefslogtreecommitdiffstats
path: root/application/service/files.php
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2015-01-11 23:35:38 +0100
committerFlorian Pritz <bluewind@xinu.at>2015-01-16 17:38:38 +0100
commit01c881fd2c0f0c701a83e135f2142c9db3052422 (patch)
treec596b76c4b71f941c3a691977a3042a8fdf7acb1 /application/service/files.php
parentc8e5f5a20c9e558efbd5e9c152f086ab72015ba3 (diff)
fix multipaste in service/history
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'application/service/files.php')
-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