Robin Ward 57ee779b1e FIX: Job exception: undefined method `email' for nil:NilClass
It seems that due to jobs being asynchronous and wrapping code in a
DistributedMutex that by the time we run the
`UserAvatar#update_gravatar!` job that the user/user email might be
destroyed.

This patch checks before a call to `user.email_hash` to make sure
the user and primary email exist to prevent the exception. If not
present, the job exits as there's nothing to do because we are
probably running after the user was destroyed for some reason.
2019-03-08 13:39:56 -05:00
..
2018-07-16 14:19:07 +08:00
2018-07-16 14:19:07 +08:00
2018-12-04 10:48:16 +01:00
2019-01-11 14:30:19 -05:00
2019-02-08 12:12:38 +01:00
2018-07-16 14:19:07 +08:00
2018-07-16 14:19:07 +08:00
2018-07-16 14:19:07 +08:00
2019-02-15 10:24:29 +11:00
2018-08-23 09:44:15 +02:00
2018-07-16 14:19:07 +08:00
2018-07-16 14:19:07 +08:00
2019-01-11 14:30:19 -05:00
2018-07-16 14:19:07 +08:00
2019-01-07 18:11:43 +01:00
2019-02-08 12:12:38 +01:00
2019-02-08 12:12:38 +01:00
2018-07-16 14:19:07 +08:00
2018-10-08 18:01:21 +02:00
2018-07-16 14:19:07 +08:00