Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
0.00% |
0 / 5 |
|
0.00% |
0 / 1 |
CRAP | |
0.00% |
0 / 1 |
| RefreshTokenEntity | |
0.00% |
0 / 5 |
|
0.00% |
0 / 1 |
2 | |
0.00% |
0 / 1 |
| jsonSerialize | |
0.00% |
0 / 5 |
|
0.00% |
0 / 1 |
2 | |||
| 1 | <?php |
| 2 | |
| 3 | namespace MediaWiki\Extension\OAuth\Entity; |
| 4 | |
| 5 | use JsonSerializable; |
| 6 | use League\OAuth2\Server\Entities\RefreshTokenEntityInterface; |
| 7 | use League\OAuth2\Server\Entities\Traits\EntityTrait; |
| 8 | use League\OAuth2\Server\Entities\Traits\RefreshTokenTrait; |
| 9 | |
| 10 | class RefreshTokenEntity implements RefreshTokenEntityInterface, JsonSerializable { |
| 11 | use RefreshTokenTrait; |
| 12 | use EntityTrait; |
| 13 | |
| 14 | public function jsonSerialize(): array { |
| 15 | return [ |
| 16 | 'identifier' => $this->getIdentifier(), |
| 17 | 'accessToken' => $this->getAccessToken()->getIdentifier(), |
| 18 | 'expires' => $this->getExpiryDateTime()->getTimestamp() |
| 19 | ]; |
| 20 | } |
| 21 | } |