Fixed mail helpers that were causing failures of the travis build