From b8e45c868afab9731018d0d2c31a683eb6876967 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Fri, 23 Oct 2020 20:05:17 +0100 Subject: [PATCH] Tidying --- follow.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/follow.py b/follow.py index 1616c0fd..a38a2007 100644 --- a/follow.py +++ b/follow.py @@ -8,6 +8,7 @@ __status__ = "Production" from pprint import pprint import os +from utils import isSystemAccount from utils import getFollowersList from utils import validNickname from utils import domainPermitted @@ -574,9 +575,9 @@ def receiveFollowRequest(session, baseDir: str, httpPrefix: str, print('DEBUG: follow request does not contain a ' + 'nickname for the account followed') return True - if nicknameToFollow == 'news' or nicknameToFollow == 'inbox': + if isSystemAccount(nicknameToFollow): if debug: - print('DEBUG: Cannot follow the news or inbox accounts') + print('DEBUG: Cannot follow system account - ' + nicknameToFollow) return True handleToFollow = nicknameToFollow + '@' + domainToFollow if domainToFollow == domain: