Skip to content

Commit

Permalink
fix: Use proper user when unlocking an app locked file with occ
Browse files Browse the repository at this point in the history
Signed-off-by: Julius Knorr <jus@bitgrid.net>
  • Loading branch information
juliusknorr authored and backportbot[bot] committed Dec 16, 2024
1 parent 13784c6 commit 2522330
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Service/LockService.php
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ public function unlockFile(int $fileId, string $userId, bool $force = false, int
}

if ($force) {
$userId = $lock->getOwner();
$userId = in_array($lock->getType(), [ILock::TYPE_USER, ILock::TYPE_TOKEN]) ? $lock->getOwner() : $userId;
$lockType = $lock->getType();
}

Expand Down

0 comments on commit 2522330

Please sign in to comment.