[scrobbles] Fix scrobble having no user in tests
This commit is contained in:
@ -560,7 +560,7 @@ class Scrobble(TimeStampedModel):
|
|||||||
|
|
||||||
if not self.timezone:
|
if not self.timezone:
|
||||||
timezone = settings.TIME_ZONE
|
timezone = settings.TIME_ZONE
|
||||||
if self.user.profile:
|
if self.user and self.user.profile:
|
||||||
timezone = self.user.profile.timezone
|
timezone = self.user.profile.timezone
|
||||||
self.timzeone = timezone
|
self.timzeone = timezone
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user