 }
 
 extension HTTPStream {
-    func receiveByte() throws -> Byte {
-        repeat {
-            if let byte = try receive(max: 1).first {
-                return byte
-            }
-        } while true
+    func receiveByte() throws -> Byte? {
+        return try receive(max: 1).first
     }
 
     func receiveLine() throws -> String {
         var line: String = ""
 
-        func append(byte: Byte?) {
-            guard let byte = byte else {
-                return
-            }
+        func append(byte: Byte) {
             guard byte >= minimumValidAsciiCharacter else {
                 return
             }


    func listen() throws

    func receiveByte() throws -> Byte
    func receiveLine() throws -> String

    func sendHeaderEndOfLine() throws

            line.append(Character(byte))
        }

        while !closed, let byte = try receiveByte() where byte != newLine {
            append(byte)
        }

