summaryrefslogtreecommitdiffstats
path: root/lib/files/cache/permissions.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/files/cache/permissions.php')
-rw-r--r--lib/files/cache/permissions.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/files/cache/permissions.php b/lib/files/cache/permissions.php
index e24c05b10a3..e1735831b94 100644
--- a/lib/files/cache/permissions.php
+++ b/lib/files/cache/permissions.php
@@ -51,9 +51,11 @@ class Permissions {
*/
public function set($fileId, $user, $permissions) {
if (self::get($fileId, $user) !== -1) {
- $query = \OC_DB::prepare('UPDATE `*PREFIX*permissions` SET `permissions` = ? WHERE `user` = ? AND `fileid` = ?');
+ $query = \OC_DB::prepare('UPDATE `*PREFIX*permissions` SET `permissions` = ?'
+ .' WHERE `user` = ? AND `fileid` = ?');
} else {
- $query = \OC_DB::prepare('INSERT INTO `*PREFIX*permissions`(`permissions`, `user`, `fileid`) VALUES(?, ?,? )');
+ $query = \OC_DB::prepare('INSERT INTO `*PREFIX*permissions`(`permissions`, `user`, `fileid`)'
+ .' VALUES(?, ?,? )');
}
$query->execute(array($permissions, $user, $fileId));
}
@@ -73,7 +75,8 @@ class Permissions {
$params[] = $user;
$inPart = implode(', ', array_fill(0, count($fileIds), '?'));
- $query = \OC_DB::prepare('SELECT `fileid`, `permissions` FROM `*PREFIX*permissions` WHERE `fileid` IN (' . $inPart . ') AND `user` = ?');
+ $query = \OC_DB::prepare('SELECT `fileid`, `permissions` FROM `*PREFIX*permissions`'
+ .' WHERE `fileid` IN (' . $inPart . ') AND `user` = ?');
$result = $query->execute($params);
$filePermissions = array();
while ($row = $result->fetchRow()) {