Closes #1. Yaml block only created if root node as attribute(s).
Yaml only created if root node has attribute(s). Close #1