Fixed reference to pattern.lines (was still referencing pattern.pattern)
Merge pull request #3 from eboskma/fix-bug-in-writing-pattern

Fixed reference to pattern.lines (was still referencing pattern.pattern)