Modified for mail setting