This class seems to be duplicated in your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate
the same code in three or more different places, we strongly encourage you to
look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.
Loading history...
9
{
10
/**
11
* Gets socket from current connection
12
*
13
* @deprecated
14
*/
15
public function getSocket()
16
{
17
$this->connect();
18
19
return parent::getSocket();
20
}
21
22
/**
23
* {@inheritdoc}
24
*/
25
public function channel($channel_id = null)
26
{
27
$this->connect();
28
29
return parent::channel($channel_id);
30
}
31
32
/**
33
* @return null|\PhpAmqpLib\Wire\IO\AbstractIO
34
*/
35
protected function getIO()
36
{
37
if (!$this->io) {
38
$this->connect();
39
}
40
41
return $this->io;
42
}
43
44
/**
45
* Should the connection be attempted during construction?
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.