Protect against case where user is null.

User field is nullable but some functions don't check for None before trying to access fields
Merge pull request #44 from twoolie/patch-1

Protect against case where user is null.