Code Duplication    Length = 19-19 lines in 3 locations

Model/HistoryCommand.php 1 location

@@ 20-38 (lines=19) @@
17
 *
18
 * @author Artem Henvald <[email protected]>
19
 */
20
final class HistoryCommand extends AbstractCommand implements ResultableCommandInterface
21
{
22
    use ChannelCommandTrait;
23
24
    /**
25
     * @param string $channel
26
     */
27
    public function __construct(string $channel)
28
    {
29
        $this->channel = $channel;
30
31
        parent::__construct(
32
            Method::HISTORY,
33
            [
34
                'channel' => $channel,
35
            ]
36
        );
37
    }
38
}
39

Model/PresenceCommand.php 1 location

@@ 20-38 (lines=19) @@
17
 *
18
 * @author Artem Henvald <[email protected]>
19
 */
20
final class PresenceCommand extends AbstractCommand implements ResultableCommandInterface
21
{
22
    use ChannelCommandTrait;
23
24
    /**
25
     * @param string $channel
26
     */
27
    public function __construct(string $channel)
28
    {
29
        $this->channel = $channel;
30
31
        parent::__construct(
32
            Method::PRESENCE,
33
            [
34
                'channel' => $channel,
35
            ]
36
        );
37
    }
38
}
39

Model/PresenceStatsCommand.php 1 location

@@ 20-38 (lines=19) @@
17
 *
18
 * @author Artem Henvald <[email protected]>
19
 */
20
final class PresenceStatsCommand extends AbstractCommand implements ResultableCommandInterface
21
{
22
    use ChannelCommandTrait;
23
24
    /**
25
     * @param string $channel
26
     */
27
    public function __construct(string $channel)
28
    {
29
        $this->channel = $channel;
30
31
        parent::__construct(
32
            Method::PRESENCE_STATS,
33
            [
34
                'channel' => $channel,
35
            ]
36
        );
37
    }
38
}
39