| Total Complexity | 4 |
| Total Lines | 44 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 13 | class NoConfirmation implements ConfirmationInterface |
||
| 14 | { |
||
| 15 | /** |
||
| 16 | * Get copy with storage service. |
||
| 17 | * |
||
| 18 | * @param Storage $storage |
||
| 19 | * @return static |
||
| 20 | */ |
||
| 21 | 1 | public function withStorage(Storage $storage) |
|
| 22 | { |
||
| 23 | 1 | return $this; |
|
| 24 | } |
||
| 25 | |||
| 26 | /** |
||
| 27 | * Create a copy of this service with a specific subject. |
||
| 28 | * |
||
| 29 | * @param string $subject |
||
| 30 | * @return static |
||
| 31 | */ |
||
| 32 | 1 | public function withSubject(string $subject) |
|
| 35 | } |
||
| 36 | |||
| 37 | /** |
||
| 38 | * Generate a confirmation token. |
||
| 39 | * |
||
| 40 | * @throws \LogicException |
||
| 41 | */ |
||
| 42 | 1 | public function getToken(User $user, \DateTimeInterface $expire): string |
|
| 45 | } |
||
| 46 | |||
| 47 | /** |
||
| 48 | * Get user by confirmation token. |
||
| 49 | * |
||
| 50 | * @param string $token Confirmation token |
||
| 51 | * @return User |
||
| 52 | * @throws \LogicException |
||
| 53 | */ |
||
| 54 | 1 | public function from(string $token): User |
|
| 57 | } |
||
| 58 | } |
||
| 59 |