restore password reset function for db authentication
add tests for Message.create_with_recipients
fix message distribution

Message distribution was broken by me with commit
f731af26eb8e505df88725ded54a96729be95572

Obviously, we can only distribute the message once all recipients have
been recorded, not right after the message record alone has been
created.

Added distribution tests to make sure this won't happen again.
add test: river queries work with non-ASCII chars