Code Duplication    Length = 6-7 lines in 2 locations

src/Frame/PriorityTrait.php 1 location

@@ 17-22 (lines=6) @@
14
    protected $stream_weight;
15
    protected $exclusive;
16
17
    public function __construct(array $options = [])
18
    {
19
        parent::__construct($options);
20
        $this->depends_on = (int) ($options['depends_on'] ?? 0);
21
        $this->stream_weight = (int) ($options['stream_weight'] ?? 0);
22
        $this->exclusive = (bool) ($options['exclusive'] ?? false);
23
    }
24
25
    /**

src/Frame/GoAwayFrame.php 1 location

@@ 24-30 (lines=7) @@
21
    protected $error_code;
22
    protected $additional_data;
23
24
    public function __construct(array $options = [])
25
    {
26
        parent::__construct($options);
27
        $this->last_stream_id = (int) ($options['last_stream_id'] ?? 0);
28
        $this->error_code = (int) ($options['error_code'] ?? 0);
29
        $this->additional_data = (int) ($options['additional_data'] ?? '');
30
    }
31
32
    public function serializeBody(): string
33
    {