1
0
mirror of https://github.com/httpie/cli.git synced 2025-08-10 22:42:05 +02:00

Improved request formatting.

This commit is contained in:
Jakub Roztocil
2012-03-14 19:30:58 +01:00
parent ccbea8c96e
commit e2e749b2a6
2 changed files with 9 additions and 4 deletions

View File

@@ -39,9 +39,9 @@ def format_http_message(message, prettifier=None,
else:
bits.append(message.line)
bits.append(message.headers)
if with_body:
if with_body and message.body:
bits.append('\n')
if with_body:
if with_body and message.body:
if prettifier and message.content_type:
bits.append(prettifier.body(message.body, message.content_type))
else: