mirror of https://gitlab.com/bashrc2/epicyon
Set flag if users path is found
parent
4697de88c0
commit
907f3d8366
|
@ -1220,6 +1220,7 @@ def getActorJson(hostDomain: str, handle: str, http: bool, gnunet: bool,
|
||||||
nickname = handle.split(userPath)[1]
|
nickname = handle.split(userPath)[1]
|
||||||
nickname = nickname.replace('\n', '').replace('\r', '')
|
nickname = nickname.replace('\n', '').replace('\r', '')
|
||||||
domain = handle.split(userPath)[0]
|
domain = handle.split(userPath)[0]
|
||||||
|
userPathFound = True
|
||||||
break
|
break
|
||||||
if not userPathFound and '://' in originalHandle:
|
if not userPathFound and '://' in originalHandle:
|
||||||
domain = originalHandle.split('://')[1]
|
domain = originalHandle.split('://')[1]
|
||||||
|
@ -1245,6 +1246,7 @@ def getActorJson(hostDomain: str, handle: str, http: bool, gnunet: bool,
|
||||||
nickname = handle.split('@')[0]
|
nickname = handle.split('@')[0]
|
||||||
domain = handle.split('@')[1]
|
domain = handle.split('@')[1]
|
||||||
domain = domain.replace('\n', '').replace('\r', '')
|
domain = domain.replace('\n', '').replace('\r', '')
|
||||||
|
|
||||||
cachedWebfingers = {}
|
cachedWebfingers = {}
|
||||||
proxyType = None
|
proxyType = None
|
||||||
if http or domain.endswith('.onion'):
|
if http or domain.endswith('.onion'):
|
||||||
|
|
20
skills.py
20
skills.py
|
@ -83,17 +83,15 @@ def setActorSkillLevel(actorJson: {},
|
||||||
if not actorJson:
|
if not actorJson:
|
||||||
return True
|
return True
|
||||||
if not actorJson.get('hasOccupation'):
|
if not actorJson.get('hasOccupation'):
|
||||||
actorJson['hasOccupation'] = [
|
actorJson['hasOccupation'] = [{
|
||||||
{
|
'@type': 'Occupation',
|
||||||
'@type': 'Occupation',
|
'name': '',
|
||||||
'name': '',
|
"occupationLocation": {
|
||||||
"occupationLocation": {
|
"@type": "City",
|
||||||
"@type": "City",
|
"name": "Fediverse"
|
||||||
"name": "Fediverse"
|
},
|
||||||
},
|
'skills': []
|
||||||
'skills': []
|
}]
|
||||||
}
|
|
||||||
]
|
|
||||||
ocSkillsList = getOccupationSkills(actorJson)
|
ocSkillsList = getOccupationSkills(actorJson)
|
||||||
skillsDict = getSkillsFromList(ocSkillsList)
|
skillsDict = getSkillsFromList(ocSkillsList)
|
||||||
if not skillsDict.get(skill):
|
if not skillsDict.get(skill):
|
||||||
|
|
Loading…
Reference in New Issue