Fix coding styles

Signed-off-by: Julius Härtl <jus@bitgrid.net>
Signed-off-by: Max <max@nextcloud.com>
This commit is contained in:
Sergey Shliakhov
2020-07-18 09:02:28 +03:00
committed by Julius Härtl
parent bdf4631504
commit cfbc18deb9
5 changed files with 89 additions and 89 deletions

View File

@@ -155,16 +155,16 @@ class AssignmentMapper extends QBMapper implements IPermissionMapper {
public function transferOwnership($ownerId, $newOwnerId) {
$params = [
'newOwner' => $newOwnerId,
'type' => AssignedUsers::TYPE_USER
'type' => AssignedUsers::TYPE_USER
];
$sql = "DELETE FROM `{$this->tableName}` WHERE `participant` = :newOwner AND `type`= :type";
$stmt = $this->execute($sql, $params);
$stmt->closeCursor();
$params = [
'owner' => $ownerId,
'newOwner' => $newOwnerId,
'type' => AssignedUsers::TYPE_USER
];
$sql = "DELETE FROM `{$this->tableName}` WHERE `participant` = :newOwner AND `type`= :type";
$stmt = $this->execute($sql, $params);
$stmt->closeCursor();
$params = [
'owner' => $ownerId,
'newOwner' => $newOwnerId,
'type' => AssignedUsers::TYPE_USER
];
$sql = "UPDATE `{$this->tableName}` SET `participant` = :newOwner WHERE `participant` = :owner AND `type`= :type";
$stmt = $this->execute($sql, $params);
$stmt->closeCursor();