From 4937bf9d91a4be17213513eca47a2e0c4e1d3a45 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Mon, 19 Aug 2019 13:40:59 +0100 Subject: [PATCH] Mentioned recipients may not exist --- posts.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/posts.py b/posts.py index 09d85f43..f4b2d896 100644 --- a/posts.py +++ b/posts.py @@ -471,9 +471,10 @@ def createPostBase(baseDir: str,nickname: str, domain: str, port: int, \ toRecipients=[toUrl] # who to send to - for mention in mentionedRecipients: - if mention not in toRecipients: - toRecipients.append(mention) + if mentionedRecipients: + for mention in mentionedRecipients: + if mention not in toRecipients: + toRecipients.append(mention) # create a list of hashtags if hashtagsDict: