Deal with active record not found exceptions when creating message. Some tidying...