diff --git a/README.md b/README.md index b60bd94..f05cbf9 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,13 @@ This was originally written before [alerts](https://www.redflagdeals.com/alerts/ ## Usage -To run the code directly, clone this repo and run the following: +The simplest way to get started is to clone this repo, and run with docker: + +```sh +docker run -it -v "$(pwd)/examples/config.yml:/app/config.yml" ghcr.io/davegallant/rfd-notify:1 +``` + +To run the code with [poetry](https://python-poetry.org/), clone this repo and run the following: ```shell poetry install diff --git a/rfd_notify/rfd.py b/rfd_notify/rfd.py index 7b1fee4..8046cdb 100644 --- a/rfd_notify/rfd.py +++ b/rfd_notify/rfd.py @@ -63,7 +63,10 @@ def look_for_matches( for expression in config.expressions: expression = expression.lower() topic_title = topic.title.lower() - dealer_name = topic.offer.dealer_name.lower() + if topic.offer.dealer_name: + dealer_name = topic.offer.dealer_name.lower() + else: + dealer_name = "" if re.search(expression, topic_title): found_match = True logger.debug(