Code Duplication    Length = 4-4 lines in 2 locations

PHPDaemon/Servers/HTTP/Connection.php 1 location

@@ 136-139 (lines=4) @@
133
            if (isset($e[1])) {
134
                $this->currentHeader                            = 'HTTP_' . strtoupper(strtr($e[0], Generic::$htr));
135
                $this->req->attrs->server[$this->currentHeader] = $e[1];
136
            } elseif (($e[0][0] === "\t" || $e[0][0] === "\x20") && $this->currentHeader) {
137
                // multiline header continued
138
                $this->req->attrs->server[$this->currentHeader] .= $e[0];
139
            } else {
140
                // whatever client speaks is not HTTP anymore
141
                $this->badRequest($this->req);
142
                return false;

PHPDaemon/Servers/WebSocket/Connection.php 1 location

@@ 337-340 (lines=4) @@
334
            if (isset($e[1])) {
335
                $this->currentHeader                = 'HTTP_' . strtoupper(strtr($e[0], Generic::$htr));
336
                $this->server[$this->currentHeader] = $e[1];
337
            } elseif (($e[0][0] === "\t" || $e[0][0] === "\x20") && $this->currentHeader) {
338
                // multiline header continued
339
                $this->server[$this->currentHeader] .= $e[0];
340
            } else {
341
                // whatever client speaks is not HTTP anymore
342
                $this->badRequest();
343
                return false;