diff --git a/ytmusicapi/helpers.py b/ytmusicapi/helpers.py index 128b2bf..ac6c015 100644 --- a/ytmusicapi/helpers.py +++ b/ytmusicapi/helpers.py @@ -96,7 +96,7 @@ def get_datestamp(): def to_int(string): - number_string = re.split('[\x20\xa0]', string)[0] + number_string = re.sub('[^\\d]', '', string) try: int_value = locale.atoi(number_string) except ValueError: