Revert "Fixing database"

This reverts commit e76a46242ffa6804cee28c1d9ab12f572dbfac89.
Deleted unrelated mailer stuff