Less indentation

main
Bob Mottram 2024-05-10 10:44:26 +01:00
parent 53eeb041fd
commit 803fed70b0
1 changed files with 480 additions and 472 deletions

View File

@ -118,7 +118,15 @@ def receive_search_query(self, calling_domain: str, cookie: str,
default_timeline, cookie, calling_domain, 303)
self.server.postreq_busy = False
return
if 'searchtext=' in search_params:
if 'searchtext=' not in search_params:
actor_str = \
get_instance_url(calling_domain, http_prefix, domain_full,
onion_domain, i2p_domain) + users_path
redirect_headers(self, actor_str + '/' + default_timeline,
cookie, calling_domain, 303)
self.server.postreq_busy = False
return
search_str = search_params.split('searchtext=')[1]
if '&' in search_str:
search_str = search_str.split('&')[0]
@ -603,10 +611,10 @@ def receive_search_query(self, calling_domain: str, cookie: str,
write2(self, msg)
self.server.postreq_busy = False
return
actor_str = \
get_instance_url(calling_domain, http_prefix,
domain_full, onion_domain, i2p_domain) + \
users_path
domain_full, onion_domain, i2p_domain) + users_path
redirect_headers(self, actor_str + '/' + default_timeline,
cookie, calling_domain, 303)
self.server.postreq_busy = False