From 9935c71ec310b45a7cfcf0bad286eace4192ebb4 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Mon, 16 Mar 2020 08:52:46 +0100 Subject: Check the user on remote wipe Signed-off-by: Joas Schilling --- lib/private/Authentication/Token/RemoteWipe.php | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'lib') diff --git a/lib/private/Authentication/Token/RemoteWipe.php b/lib/private/Authentication/Token/RemoteWipe.php index 2285ccd2cd8..e0fbf0734f5 100644 --- a/lib/private/Authentication/Token/RemoteWipe.php +++ b/lib/private/Authentication/Token/RemoteWipe.php @@ -57,18 +57,14 @@ class RemoteWipe { } /** - * @param int $id - * + * @param IToken $token * @return bool * * @throws InvalidTokenException * @throws WipeTokenException - * @throws ExpiredTokenException */ - public function markTokenForWipe(int $id): bool { - $token = $this->tokenProvider->getTokenById($id); - - if (!($token instanceof IWipeableToken)) { + public function markTokenForWipe(IToken $token): bool { + if (!$token instanceof IWipeableToken) { return false; } -- cgit v1.2.3