mirror of https://gitlab.com/bashrc2/epicyon
Don't need actorLiked
parent
50ea25d767
commit
4b39111b38
10
daemon.py
10
daemon.py
|
@ -1510,11 +1510,11 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
return
|
return
|
||||||
|
|
||||||
# like from the web interface icon
|
# like from the web interface icon
|
||||||
if htmlGET and '?like=' in self.path and '/statuses/' in self.path:
|
if htmlGET and '?like=' in self.path:
|
||||||
pageNumber=1
|
pageNumber=1
|
||||||
likeUrl=self.path.split('?like=')[1]
|
likeUrl=self.path.split('?like=')[1]
|
||||||
if '?' in likeUrl:
|
if '?' in likeUrl:
|
||||||
likeUrl=likeUrl.split('?')[0]
|
likeUrl=likeUrl.split('?')[0]
|
||||||
actor=self.path.split('?like=')[0]
|
actor=self.path.split('?like=')[0]
|
||||||
if '?page=' in self.path:
|
if '?page=' in self.path:
|
||||||
pageNumberStr=self.path.split('?page=')[1]
|
pageNumberStr=self.path.split('?page=')[1]
|
||||||
|
@ -1540,8 +1540,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
createSession(self.server.useTor)
|
createSession(self.server.useTor)
|
||||||
likeActor= \
|
likeActor= \
|
||||||
self.server.httpPrefix+'://'+ \
|
self.server.httpPrefix+'://'+ \
|
||||||
self.server.domainFull+'/users/'+self.postToNickname
|
self.server.domainFull+'/users/'+self.postToNickname
|
||||||
actorLiked=likeUrl.split('/statuses/')[0]
|
|
||||||
likeJson= {
|
likeJson= {
|
||||||
"@context": "https://www.w3.org/ns/activitystreams",
|
"@context": "https://www.w3.org/ns/activitystreams",
|
||||||
'type': 'Like',
|
'type': 'Like',
|
||||||
|
@ -1555,7 +1554,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
return
|
return
|
||||||
|
|
||||||
# undo a like from the web interface icon
|
# undo a like from the web interface icon
|
||||||
if htmlGET and '?unlike=' in self.path and '/statuses/' in self.path:
|
if htmlGET and '?unlike=' in self.path:
|
||||||
pageNumber=1
|
pageNumber=1
|
||||||
likeUrl=self.path.split('?unlike=')[1]
|
likeUrl=self.path.split('?unlike=')[1]
|
||||||
if '?' in likeUrl:
|
if '?' in likeUrl:
|
||||||
|
@ -1585,7 +1584,6 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
undoActor= \
|
undoActor= \
|
||||||
self.server.httpPrefix+'://'+ \
|
self.server.httpPrefix+'://'+ \
|
||||||
self.server.domainFull+'/users/'+self.postToNickname
|
self.server.domainFull+'/users/'+self.postToNickname
|
||||||
actorLiked=likeUrl.split('/statuses/')[0]
|
|
||||||
undoLikeJson= {
|
undoLikeJson= {
|
||||||
"@context": "https://www.w3.org/ns/activitystreams",
|
"@context": "https://www.w3.org/ns/activitystreams",
|
||||||
'type': 'Undo',
|
'type': 'Undo',
|
||||||
|
|
Loading…
Reference in New Issue