From c3052a06194188aff0a7c560097bf8e90aa6b275 Mon Sep 17 00:00:00 2001 From: pictuga Date: Sat, 11 Sep 2021 21:50:09 +0200 Subject: [PATCH] morss: do not crash on empty pages --- morss/morss.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/morss/morss.py b/morss/morss.py index 10b2b73..bcc4069 100644 --- a/morss/morss.py +++ b/morss/morss.py @@ -218,6 +218,10 @@ def ItemFill(item, options, feedurl='/', fast=False): log('non-text page') return True + if not req['data']: + log('empty page') + return True + out = readabilite.get_article(req['data'], url=req['url'], encoding_in=req['encoding'], encoding_out='unicode') if out is not None: