Refactored to pass tests

This commit is contained in:
Manveer Basra
2018-10-30 16:38:15 -04:00
committed by Ritiek Malhotra
parent cf9b0690fd
commit c886ccf603

View File

@@ -17,7 +17,7 @@ spotify = None
def generate_token():
""" Generate the token. """
if const.args.spotify_client_id and const.args.spotify_client_secret:
if const.args is not None and const.args.spotify_client_id and const.args.spotify_client_secret:
credentials = oauth2.SpotifyClientCredentials(
client_id=const.args.spotify_client_id,
client_secret=const.args.spotify_client_secret,