Skip to content

Commit 8caba00

Browse files
committed
Fix an indentation bug
committer: Ralf Schlatterbeck <[email protected]>
1 parent e8e2f86 commit 8caba00

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

roundup/rest.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -796,16 +796,16 @@ def dispatch(self, method, uri, input):
796796
self, "%s_element" % method.lower()
797797
)(class_name, item_id, input)
798798

799-
if format_output.lower() == "json":
800-
self.client.setHeader("Content-Type", "application/json")
801-
if pretty_output:
802-
indent = 4
803-
else:
804-
indent = None
805-
output = RoundupJSONEncoder(indent=indent).encode(output)
799+
if format_output.lower() == "json":
800+
self.client.setHeader("Content-Type", "application/json")
801+
if pretty_output:
802+
indent = 4
806803
else:
807-
self.client.response_code = 406
808-
output = "Content type is not accepted by client"
804+
indent = None
805+
output = RoundupJSONEncoder(indent=indent).encode(output)
806+
else:
807+
self.client.response_code = 406
808+
output = "Content type is not accepted by client"
809809

810810
return output
811811

0 commit comments

Comments
 (0)