add tests
refact mailer view
add some extra settings