forked from indymedia/epicyon
Sequence
This commit is contained in:
1 parent
0a3e50ad3b
commit
99ed86566d
1 file changed
+2
-2
@@ -64,10 +64,10 @@ def urlPermitted(url: str, federationList: [],capability: str):
|
||||
def getPreferredName(actor: str,personCache: {}) -> str:
|
||||
"""Returns the preferred name for the given actor
|
||||
"""
|
||||
if not personCache.get(actor):
|
||||
return None
|
||||
if '/statuses/' in actor:
|
||||
actor=actor.split('/statuses/')[0]
|
||||
if not personCache.get(actor):
|
||||
return None
|
||||
if personCache[actor].get('actor'):
|
||||
if personCache[actor]['actor'].get('preferredUsername'):
|
||||
return personCache[actor]['actor']['preferredUsername']
|
||||
|
||||
Reference in new issue
Block a user