Skip to content

Commit

Permalink
fix: psalm
Browse files Browse the repository at this point in the history
Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
  • Loading branch information
solracsf authored Feb 8, 2025
1 parent 2f006e5 commit 7394e08
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions apps/files_trashbin/lib/Trashbin.php
Original file line number Diff line number Diff line change
Expand Up @@ -382,8 +382,7 @@ private static function getConfiguredTrashbinSize(string $user): int|float {
*/
private static function retainVersions($filename, $owner, $ownerPath, $timestamp) {
if (Server::get(IAppManager::class)->isEnabledForUser('files_versions') && !empty($ownerPath)) {
$userSession = Server::get(IUserSession::class);
$user = $userSession->getUser();
$user = Server::get(IUserSession::class)->getUser()->getUID();
$rootView = new View('/');

if ($rootView->is_dir($owner . '/files_versions/' . $ownerPath)) {
Expand Down Expand Up @@ -1155,8 +1154,7 @@ public static function getTrashFilename(string $filename, int $timestamp): strin
}

private static function getNodeForPath(string $path): Node {
$userSession = Server::get(IUserSession::class);
$user = $userSession->getUser();
$user = Server::get(IUserSession::class)->getUser()->getUID();
$rootFolder = Server::get(IRootFolder::class);

if ($user !== false) {
Expand Down

0 comments on commit 7394e08

Please sign in to comment.