Add check in case parsedate failed.

email.utils.parsedate returns None if failed to parse date, add a check
to handle that.
Merge pull request #805 from chinyue/master

Add check in case email.utils.parsedate failed