Fix plain text stored to HTML

Fixes most of #148