summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/public/share.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/public/share.php b/lib/public/share.php
index 6178a5ae043..e887740ac4c 100644
--- a/lib/public/share.php
+++ b/lib/public/share.php
@@ -826,8 +826,10 @@ class Share {
$date = date('Y-m-d H:i', $date->format('U') - $date->getOffset());
}
$query = \OC_DB::prepare('UPDATE `*PREFIX*share` SET `expiration` = ? WHERE `id` = ?');
+ $query->bindValue(1, $date);
foreach ($items as $item) {
- $query->execute(array($date, $item['id']));
+ $query->bindValue(2, (int) $item['id']);
+ $query->execute();
}
return true;
}