aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/Authentication/Exceptions/ExpiredTokenException.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/Authentication/Exceptions/ExpiredTokenException.php')
-rw-r--r--lib/private/Authentication/Exceptions/ExpiredTokenException.php28
1 files changed, 28 insertions, 0 deletions
diff --git a/lib/private/Authentication/Exceptions/ExpiredTokenException.php b/lib/private/Authentication/Exceptions/ExpiredTokenException.php
new file mode 100644
index 00000000000..eed2358d29d
--- /dev/null
+++ b/lib/private/Authentication/Exceptions/ExpiredTokenException.php
@@ -0,0 +1,28 @@
+<?php
+
+declare(strict_types=1);
+
+/**
+ * SPDX-FileCopyrightText: 2018 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-License-Identifier: AGPL-3.0-or-later
+ */
+namespace OC\Authentication\Exceptions;
+
+use OC\Authentication\Token\IToken;
+
+/**
+ * @deprecated 28.0.0 use {@see \OCP\Authentication\Exceptions\ExpiredTokenException} instead
+ */
+class ExpiredTokenException extends \OCP\Authentication\Exceptions\ExpiredTokenException {
+ public function __construct(
+ IToken $token,
+ ) {
+ parent::__construct($token);
+ }
+
+ public function getToken(): IToken {
+ $token = parent::getToken();
+ /** @var IToken $token We know that we passed OC interface from constructor */
+ return $token;
+ }
+}