Passed
Pull Request — master (#1316)
by
unknown
32:56
created

IdTokenClaimsCreatedEvent::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 2
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace League\OAuth2\Server;
6
7
use Lcobucci\JWT\Builder;
8
9
/**
10
 * IdTokenClaimsCreatedEvent Event helps to extend claims of the id_token
11
 *
12
 * A usecase is to add nonce If requested by the client
13
 *
14
 * @author Marc Riemer <[email protected]>
15
 */
16
final class IdTokenClaimsCreatedEvent extends IdTokenEvent
17
{
18
    /**
19
     * Builder
20
     */
21
    private Builder $builder;
22
23
    public function __construct(string $name, Builder $builder)
24
    {
25
        parent::__construct($name);
26
        $this->builder = $builder;
27
    }
28
29
    public function getBuilder(): Builder
30
    {
31
        return $this->builder;
32
    }
33
}
34