Extra follow checks

master
Bob Mottram 2019-07-17 12:24:11 +01:00
parent a47538653a
commit fb31927502
2 changed files with 6 additions and 2 deletions

View File

@ -425,6 +425,8 @@ def receiveUndo(session,baseDir: str,httpPrefix: str, \
"""
if not messageJson['type'].startswith('Undo'):
return False
if debug:
print('DEBUG: Undo activity received')
if not messageJson.get('actor'):
if debug:
print('DEBUG: follow request has no actor')

View File

@ -1080,8 +1080,10 @@ def testClientToServer():
True)
for t in range(10):
if os.path.isfile(bobDir+'/accounts/bob@'+bobDomain+'/followers.txt'):
if os.path.isfile(aliceDir+'/accounts/alice@'+aliceDomain+'/following.txt'):
break
if 'alice@'+aliceDomain+':'+alicePort in open(bobDir+'/accounts/bob@'+bobDomain+'/followers.txt').read():
if os.path.isfile(aliceDir+'/accounts/alice@'+aliceDomain+'/following.txt'):
if 'bob@'+bobDomain+':'+bobPort in open(aliceDir+'/accounts/alice@'+aliceDomain+'/following.txt').read():
break
time.sleep(1)
assert os.path.isfile(bobDir+'/accounts/bob@'+bobDomain+'/followers.txt')