fix save containing pattern steps
fixes #54
Merge pull request #55 from arnaudbey/tree

fix save containing pattern steps