Code Duplication    Length = 5-5 lines in 2 locations

classes/rcon.php 2 locations

@@ 144-148 (lines=5) @@
141
                sprintf("Expected option 'timeoutSec' to be integer, got %s", gettype($this->options['timeoutSec']))
142
            );
143
        }
144
        if (!is_bool($this->options['sendHeartbeat'])) {
145
            throw new \Exception(
146
                sprintf("Expected option 'sendHeartbeat' to be boolean, got %s", gettype($this->options['sendHeartbeat']))
147
            );
148
        }
149
        if (!is_bool($this->options['autosaveBans'])) {
150
            throw new \Exception(
151
                sprintf("Expected option 'autosaveBans' to be boolean, got %s", gettype($this->options['autosaveBans']))
@@ 149-153 (lines=5) @@
146
                sprintf("Expected option 'sendHeartbeat' to be boolean, got %s", gettype($this->options['sendHeartbeat']))
147
            );
148
        }
149
        if (!is_bool($this->options['autosaveBans'])) {
150
            throw new \Exception(
151
                sprintf("Expected option 'autosaveBans' to be boolean, got %s", gettype($this->options['autosaveBans']))
152
            );
153
        }
154
    }
155
    /**
156
     * Sends the login data to the server in order to send commands later