Skip to content

Commit

Permalink
Use enum value when setting quality. Remove default quality
Browse files Browse the repository at this point in the history
  • Loading branch information
tehkillerbee committed Aug 9, 2023
1 parent e2c121f commit 6c503c7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tidalapi/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -472,16 +472,16 @@ def audio_quality(self) -> media.Quality:
return self.config.quality

@audio_quality.setter
def audio_quality(self, value=media.Quality.high):
self.config.quality = media.Quality(value)
def audio_quality(self, quality):
self.config.quality = media.Quality(quality).value

@property
def video_quality(self) -> media.Quality:
return self.config.quality

@video_quality.setter
def video_quality(self, value=media.VideoQuality.high):
self.config.video_quality = media.VideoQuality(value)
def video_quality(self, quality):
self.config.video_quality = media.VideoQuality(quality).value

def search(self, query, models=None, limit=50, offset=0):
"""Searches TIDAL with the specified query, you can also specify what models you
Expand Down

0 comments on commit 6c503c7

Please sign in to comment.