Fix issue_5931_shows_null_in_notification_while_sending_mail
Clean up code
Merge pull request #380

Fix notification showing "null" when sending mail