diff --git a/follow.py b/follow.py index e14ab804..a2da2d99 100644 --- a/follow.py +++ b/follow.py @@ -202,14 +202,14 @@ def unfollowPerson(baseDir: str, nickname: str, domain: str, if debug: print('DEBUG: follow file ' + filename + ' was not found') return False - if handleToUnfollow.lower() not in open(filename).read().lower(): + handleToUnfollowLower = handleToUnfollow.lower() + if handleToUnfollowLower not in open(filename).read().lower(): if debug: print('DEBUG: handle to unfollow ' + handleToUnfollow + ' is not in ' + filename) return with open(filename, "r") as f: lines = f.readlines() - handleToUnfollowLower = handleToUnfollow.lower() with open(filename, "w") as f: for line in lines: if line.strip("\n").strip("\r").lower() != handleToUnfollowLower: diff --git a/inbox.py b/inbox.py index e4a27672..6141a268 100644 --- a/inbox.py +++ b/inbox.py @@ -706,10 +706,9 @@ def receiveUndoFollow(session, baseDir: str, httpPrefix: str, nicknameFollowing, domainFollowingFull, nicknameFollower, domainFollowerFull, debug): - if debug: - print('DEBUG: Follower ' + - nicknameFollower + '@' + domainFollowerFull + - ' was removed') + print(nicknameFollowing + '@' + domainFollowingFull + ': ' + 'Follower ' + nicknameFollower + '@' + domainFollowerFull + + ' was removed') return True if debug: