Fix stuff; error messages.
Move error messages to templates.