fixed database
Add debug statement to mail controller