summaryrefslogtreecommitdiff
path: root/emitter.py
diff options
context:
space:
mode:
authorAnthon van der Neut <anthon@mnt.org>2018-09-20 09:00:38 +0200
committerAnthon van der Neut <anthon@mnt.org>2018-09-20 09:00:38 +0200
commitd86f67d2e0c3f730c9c8309bd28c5318c4ebcedd (patch)
tree4c035b5139f6f4a9ccf37eab656c6cf88b4af7c3 /emitter.py
parentd3bd516b32e076af856897defdad212e8fcfd878 (diff)
downloadruamel.yaml-d86f67d2e0c3f730c9c8309bd28c5318c4ebcedd.tar.gz
fix issue 236 newline without proper following indent on nested flow-style sequences.
*When this change indeed resolves your problem, please **Close** this issue*. *(You can do so using the WorkFlow pull-down (close to the top right of this page))*
Diffstat (limited to 'emitter.py')
-rw-r--r--emitter.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/emitter.py b/emitter.py
index b739a28..3e1a552 100644
--- a/emitter.py
+++ b/emitter.py
@@ -472,7 +472,7 @@ class Emitter(object):
if self.event.comment and self.event.comment[0]:
# eol comment on empty flow sequence
self.write_post_comment(self.event)
- else:
+ elif self.flow_level == 0:
self.write_line_break()
self.state = self.states.pop()
else: