curlie icon indicating copy to clipboard operation
curlie copied to clipboard

fix headers/body order in console

Open mateusz834 opened this issue 3 years ago • 0 comments

Normally curlie returns output like that (as expected):

[mateusz@arch curlie (fix)]$ curlie localhost:8080
HTTP/1.1 200 OK
Date: Fri, 20 May 2022 19:35:04 GMT
Content-Length: 30
Content-Type: text/plain; charset=utf-8

Hello
Hello
Hello
Hello
Hello

But sometimes it returns like so: (around 5% of responses)

[mateusz@arch curlie (fix)]$ curlie localhost:8080
Hello
Hello
Hello
Hello
Hello
HTTP/1.1 200 OK
Date: Fri, 20 May 2022 19:35:40 GMT
Content-Length: 30
Content-Type: text/plain; charset=utf-8

For me it only happens when querying localhost (probably because of the low latency??). This PR fixes it.

mateusz834 avatar May 20 '22 19:05 mateusz834