From 77ad88124f4ea54c1787a10b1cc6d41006a83634 Mon Sep 17 00:00:00 2001 From: Tim Van Baak Date: Mon, 8 Mar 2021 13:13:25 -0800 Subject: [PATCH] Show link text in reddit link post body --- inquisitor/templates.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/inquisitor/templates.py b/inquisitor/templates.py index 42c5e75..50487b8 100644 --- a/inquisitor/templates.py +++ b/inquisitor/templates.py @@ -104,6 +104,8 @@ class LinearCrawler: class RedditScraper: """ An engine for generating items from subreddits. + Requires defining source, subreddit_name + fetch new with RedditScraper.fetch_new(state, __name__, reddit) """ @staticmethod def fetch_new(state, name, reddit): @@ -170,7 +172,7 @@ class RedditScraper: def get_body(self, post): parts = [] if not post.is_self: - parts.append(f'link post') + parts.append(f'link: {post.url}') if hasattr(post, 'preview'): try: previews = post.preview['images'][0]['resolutions']