Refactoring: Markdown parsing