Prevents the crash

It prevents the crash when "mail" is empty