From a42e7036dbb2e15bfadec31aac2daf094c3e1298 Mon Sep 17 00:00:00 2001 From: Jonathan Sharpe Date: Wed, 9 Sep 2015 13:18:41 +0100 Subject: [PATCH] Update webtag_data.py Try to avoid QuantifiedCode warning on "Empty exception handler" --- py_wlc/data/webtag_data.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/py_wlc/data/webtag_data.py b/py_wlc/data/webtag_data.py index 4408411..8cd640b 100644 --- a/py_wlc/data/webtag_data.py +++ b/py_wlc/data/webtag_data.py @@ -100,12 +100,11 @@ def from_latest_json(cls, dir_): try: data = json.load(file_) except ValueError: - pass - else: - date = data.get("released", "") - if latest_date is None or date > latest_date: - latest_data = data - latest_date = date + continue + date = data.get("released", "") + if latest_date is None or date > latest_date: + latest_data = data + latest_date = date if latest_data is not None: return cls(**latest_data)