mirror of https://gitlab.com/bashrc2/epicyon
Return string
parent
e9a4b25c02
commit
4de310df10
|
@ -1199,17 +1199,17 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
print('vcard 1')
|
print('vcard 1')
|
||||||
if 'application/' in accept_str:
|
if 'application/' in accept_str:
|
||||||
return False
|
return False
|
||||||
print('vcard 2')
|
print('vcard 2 ' + path)
|
||||||
if not path.startswith('/users/'):
|
if not path.startswith('/users/'):
|
||||||
self._400()
|
self._400()
|
||||||
return True
|
return True
|
||||||
print('vcard 3')
|
print('vcard 3 ' + path)
|
||||||
nickname = path.split('/users/')[1]
|
nickname = path.split('/users/')[1]
|
||||||
if '/' in nickname:
|
if '/' in nickname:
|
||||||
nickname = nickname.split('/')[0]
|
nickname = nickname.split('/')[0]
|
||||||
if '?' in nickname:
|
if '?' in nickname:
|
||||||
nickname = nickname.split('?')[0]
|
nickname = nickname.split('?')[0]
|
||||||
print('vcard 4')
|
print('vcard 4 ' + nickname)
|
||||||
if self.server.vcard_is_active:
|
if self.server.vcard_is_active:
|
||||||
print('vcard is busy during request from ' + str(referer_domain))
|
print('vcard is busy during request from ' + str(referer_domain))
|
||||||
self._503()
|
self._503()
|
||||||
|
@ -1222,6 +1222,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
if os.path.isfile(actor_filename):
|
if os.path.isfile(actor_filename):
|
||||||
actor_json = load_json(actor_filename)
|
actor_json = load_json(actor_filename)
|
||||||
if not actor_json:
|
if not actor_json:
|
||||||
|
print('vcard actor not found ' + actor_filename)
|
||||||
self._404()
|
self._404()
|
||||||
self.server.vcard_is_active = False
|
self.server.vcard_is_active = False
|
||||||
return True
|
return True
|
||||||
|
@ -1235,6 +1236,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
print('vcard sent to ' + str(referer_domain))
|
print('vcard sent to ' + str(referer_domain))
|
||||||
self.server.vcard_is_active = False
|
self.server.vcard_is_active = False
|
||||||
return True
|
return True
|
||||||
|
print('vcard string not returned')
|
||||||
self._404()
|
self._404()
|
||||||
self.server.vcard_is_active = False
|
self.server.vcard_is_active = False
|
||||||
return True
|
return True
|
||||||
|
|
Loading…
Reference in New Issue