Fixed datamgr and error email

Thx tom!