From 7900ee4e3692dbd8056c3e47c81bb22eda030b65 Mon Sep 17 00:00:00 2001 From: Unit 193 Date: Mon, 14 Feb 2022 17:17:07 -0500 Subject: New upstream version 1.20.5. --- gallery_dl/text.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gallery_dl/text.py') diff --git a/gallery_dl/text.py b/gallery_dl/text.py index 74b87fb..ac4bbcb 100644 --- a/gallery_dl/text.py +++ b/gallery_dl/text.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2015-2021 Mike Fährmann +# Copyright 2015-2022 Mike Fährmann # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as @@ -168,7 +168,7 @@ def parse_bytes(value, default=0, suffixes="bkmgtp"): """Convert a bytes-amount ("500k", "2.5M", ...) to int""" try: last = value[-1].lower() - except (TypeError, KeyError, IndexError): + except (TypeError, LookupError): return default if last in suffixes: -- cgit v1.2.3