forked from indymedia/epicyon
Handle domain
parent
d2fcb37dd9
commit
08a16714c0
10
daemon.py
10
daemon.py
|
@ -309,9 +309,9 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
# There are no replies, so show empty collection
|
||||
repliesJson = {
|
||||
'@context': 'https://www.w3.org/ns/activitystreams',
|
||||
'first': self.server.httpPrefix+'://'+self.server.domain+'/users/'+nickname+'/statuses/'+statusNumber+'?page=true',
|
||||
'id': self.server.httpPrefix+'://'+self.server.domain+'/users/'+nickname+'/statuses/'+statusNumber,
|
||||
'last': self.server.httpPrefix+'://'+self.server.domain+'/users/'+nickname+'/statuses/'+statusNumber+'?page=true',
|
||||
'first': self.server.httpPrefix+'://'+domainFull+'/users/'+nickname+'/statuses/'+statusNumber+'?page=true',
|
||||
'id': self.server.httpPrefix+'://'+domainFull+'/users/'+nickname+'/statuses/'+statusNumber,
|
||||
'last': self.server.httpPrefix+'://'+domainFull+'/users/'+nickname+'/statuses/'+statusNumber+'?page=true',
|
||||
'totalItems': 0,
|
||||
'type': 'OrderedCollection'}
|
||||
self._set_headers('application/json')
|
||||
|
@ -322,10 +322,10 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
# replies exist. Itterate through the text file containing message ids
|
||||
repliesJson = {
|
||||
'@context': 'https://www.w3.org/ns/activitystreams',
|
||||
'id': self.server.httpPrefix+'://'+self.server.domain+'/users/'+nickname+'/statuses/'+statusNumber+'?page=true',
|
||||
'id': self.server.httpPrefix+'://'+domainFull+'/users/'+nickname+'/statuses/'+statusNumber+'?page=true',
|
||||
'orderedItems': [
|
||||
],
|
||||
'partOf': self.server.httpPrefix+'://'+self.server.domain+'/users/'+nickname+'/statuses/'+statusNumber,
|
||||
'partOf': self.server.httpPrefix+'://'+domainFull+'/users/'+nickname+'/statuses/'+statusNumber,
|
||||
'type': 'OrderedCollectionPage'}
|
||||
# some messages could be private, so check authorization state
|
||||
authorized=self._isAuthorized()
|
||||
|
|
Loading…
Reference in New Issue