mirror of https://gitlab.com/bashrc2/epicyon
flake8 format
parent
6b092d63ec
commit
128e431e9f
10
like.py
10
like.py
|
@ -361,10 +361,12 @@ def sendLikeViaServer(baseDir: str, session,
|
||||||
if ':' not in fromDomain:
|
if ':' not in fromDomain:
|
||||||
fromDomainFull = fromDomain + ':' + str(fromPort)
|
fromDomainFull = fromDomain + ':' + str(fromPort)
|
||||||
|
|
||||||
|
actor = httpPrefix + '://' + fromDomainFull + '/users/' + fromNickname
|
||||||
|
|
||||||
newLikeJson = {
|
newLikeJson = {
|
||||||
"@context": "https://www.w3.org/ns/activitystreams",
|
"@context": "https://www.w3.org/ns/activitystreams",
|
||||||
'type': 'Like',
|
'type': 'Like',
|
||||||
'actor': httpPrefix+'://'+fromDomainFull+'/users/'+fromNickname,
|
'actor': actor,
|
||||||
'object': likeUrl
|
'object': likeUrl
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -436,13 +438,15 @@ def sendUndoLikeViaServer(baseDir: str, session,
|
||||||
if ':' not in fromDomain:
|
if ':' not in fromDomain:
|
||||||
fromDomainFull = fromDomain + ':' + str(fromPort)
|
fromDomainFull = fromDomain + ':' + str(fromPort)
|
||||||
|
|
||||||
|
actor = httpPrefix + '://' + fromDomainFull + '/users/' + fromNickname
|
||||||
|
|
||||||
newUndoLikeJson = {
|
newUndoLikeJson = {
|
||||||
"@context": "https://www.w3.org/ns/activitystreams",
|
"@context": "https://www.w3.org/ns/activitystreams",
|
||||||
'type': 'Undo',
|
'type': 'Undo',
|
||||||
'actor': httpPrefix+'://'+fromDomainFull+'/users/'+fromNickname,
|
'actor': actor,
|
||||||
'object': {
|
'object': {
|
||||||
'type': 'Like',
|
'type': 'Like',
|
||||||
'actor': httpPrefix+'://'+fromDomainFull+'/users/'+fromNickname,
|
'actor': actor,
|
||||||
'object': likeUrl
|
'object': likeUrl
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue