Less indentation

main
Bob Mottram 2021-07-05 11:25:21 +01:00
parent cd14cc2775
commit e8d45565b4
1 changed files with 47 additions and 45 deletions

View File

@ -1977,7 +1977,8 @@ def undoAnnounceCollectionEntry(recentPostsCache: {},
shares of posts, not shares of physical objects.
"""
postJsonObject = loadJson(postFilename)
if postJsonObject:
if not postJsonObject:
return
# remove any cached version of this announce so that the announce
# icon is changed
nickname = getNicknameFromActor(actor)
@ -2014,7 +2015,8 @@ def undoAnnounceCollectionEntry(recentPostsCache: {},
postJsonObject['object']['shares']['items'].remove(anIt)
itemFound = True
break
if itemFound:
if not itemFound:
return
if totalItems == 1:
if debug:
print('DEBUG: shares (announcements) ' +