Skip to content

Commit

Permalink
Fix exception in discogs_connect when self.me
Browse files Browse the repository at this point in the history
is passed and we are offline.
  • Loading branch information
JOJ0 committed Nov 7, 2024
1 parent 3e3e1c6 commit 84f6dc9
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions discodos/model_collection.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ def discogs_connect(self, user_token=None, app_identifier=None,
discogs=None):
"""Discogs connect try,except wrapper sets attributes d, me and ONLINE.
"""
if discogs:
self.d = discogs
self.me = discogs.identity()
self.ONLINE = True
return self.ONLINE

try:
if discogs:
self.d = discogs
self.me = discogs.identity()
self.ONLINE = True
return self.ONLINE

self.d = discogs_client.Client(
app_identifier, user_token=user_token
)
Expand Down

0 comments on commit 84f6dc9

Please sign in to comment.