Code Duplication    Length = 14-14 lines in 3 locations

src/eXpansion/Bundle/AdminChat/ChatCommand/AdminReturnCommand.php 1 location

@@ 26-39 (lines=14) @@
23
    /**
24
     * @inheritdoc
25
     */
26
    public function execute($login, InputInterface $input)
27
    {
28
        $nickName = $this->playerStorage->getPlayerInfo($login)->getNickName();
29
        $group = $this->getGroupLabel($login);
30
31
        $return = $this->connection->{$this->functionName}();
32
33
        $this->chatNotification->sendMessage(
34
            $this->chatMessage,
35
            $this->isPublic ? null : $login,
36
            ['%adminLevel%' => $group, '%admin%' => $nickName, '%return%' => $return]
37
        );
38
39
    }
40
}
41

src/eXpansion/Bundle/AdminChat/ChatCommand/TimeParameterCommand.php 1 location

@@ 73-86 (lines=14) @@
70
    /**
71
     * @inheritdoc
72
     */
73
    public function execute($login, InputInterface $input)
74
    {
75
        $nickName = $this->playerStorage->getPlayerInfo($login)->getNickName();
76
        $parameter = $this->timeHelper->textToTime($input->getArgument('parameter'));
77
        $group = $this->getGroupLabel($login);
78
79
        $this->chatNotification->sendMessage(
80
            $this->chatMessage,
81
            $this->isPublic ? null : $login,
82
            ['%adminLevel%' => $group, '%admin%' => $nickName, "%parameter%" => $parameter]
83
        );
84
85
        $this->connection->{$this->functionName}($parameter);
86
    }
87
88
    /**
89
     * @param string $parameterDescription

src/eXpansion/Bundle/AdminChat/ChatCommand/OneParameterCommand.php 1 location

@@ 97-110 (lines=14) @@
94
    /**
95
     * @inheritdoc
96
     */
97
    public function execute($login, InputInterface $input)
98
    {
99
        $nickName = $this->playerStorage->getPlayerInfo($login)->getNickName();
100
        $parameter = $input->getArgument('parameter');
101
        $group = $this->getGroupLabel($login);
102
103
        $this->chatNotification->sendMessage(
104
            $this->chatMessage,
105
            $this->isPublic ? null : $login,
106
            ['%adminLevel%' => $group, '%admin%' => $nickName, "%parameter%" => $parameter]
107
        );
108
109
        $this->connection->{$this->functionName}($parameter);
110
    }
111
112
    /**
113
     * @param string $parameterDescription