Skip to content

Commit 168af3c

Browse files
committed
LoginAs: Create identity by UserManager.
1 parent 5bd5a13 commit 168af3c

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/Api/UserEndpoint.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -521,9 +521,8 @@ public function actionLoginAs(string $id): void
521521

522522
return;
523523
}
524-
525524
try {
526-
$this->userManager->getUserStorage()->setIdentity($user)->setAuthenticated(true);
525+
$this->userManager->createIdentity($user);
527526
} catch (\Throwable $e) {
528527
$this->sendError($e->getMessage());
529528
}

0 commit comments

Comments
 (0)