sqash to the prev!
Refactor mail processing routine