Issues (19)

src/ConsumeConfig.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace Kunnu\RabbitMQ;
4
5
use Illuminate\Support\Collection;
6
7
class ConsumeConfig extends Collection
8
{
9
    /**
10
     * Connection Configuration.
11
     *
12
     * @var ConnectionConfig|null
13
     */
14
    protected ?ConnectionConfig $connectionConfig;
15
16
    /**
17
     * Create a new ConsumeConfig instance.
18
     *
19
     * @param  array  $config
20
     * @param  ConnectionConfig|null  $connectionConfig
21
     */
22
    public function __construct(array $config = [], ?ConnectionConfig $connectionConfig = null)
23
    {
24
        parent::__construct($config);
0 ignored issues
show
$config of type array is incompatible with the type Illuminate\Contracts\Support\Arrayable expected by parameter $items of Illuminate\Support\Collection::__construct(). ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

24
        parent::__construct(/** @scrutinizer ignore-type */ $config);
Loading history...
25
        $this->connectionConfig = $connectionConfig;
26
    }
27
28
    /**
29
     * Get connection config.
30
     *
31
     * @return ConnectionConfig|null
32
     */
33
    public function getConnectionConfig(): ?ConnectionConfig
34
    {
35
        return $this->connectionConfig;
36
    }
37
}
38