diff options
Diffstat (limited to 'youtube/__init__.py')
-rw-r--r-- | youtube/__init__.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/youtube/__init__.py b/youtube/__init__.py index b0e8761..64aed56 100644 --- a/youtube/__init__.py +++ b/youtube/__init__.py @@ -54,7 +54,10 @@ def commatize(num): if num is None: return '' if isinstance(num, str): - num = int(num) + try: + num = int(num) + except ValueError: + return num return '{:,}'.format(num) |