mirror of https://gitlab.com/bashrc2/epicyon
Tidying
parent
f2571e380f
commit
779dac3ffa
|
|
@ -26,6 +26,9 @@ def redirect_to_login_screen(self, calling_domain: str, path: str,
|
||||||
news_instance: bool, fitness: {}) -> bool:
|
news_instance: bool, fitness: {}) -> bool:
|
||||||
"""Redirects to the login screen if necessary
|
"""Redirects to the login screen if necessary
|
||||||
"""
|
"""
|
||||||
|
if authorized:
|
||||||
|
return False
|
||||||
|
|
||||||
divert_to_login_screen = False
|
divert_to_login_screen = False
|
||||||
non_login_paths = ('/media/', '/ontologies/', '/data/', '/sharefiles/',
|
non_login_paths = ('/media/', '/ontologies/', '/data/', '/sharefiles/',
|
||||||
'/statuses/', '/emoji/', '/tags/', '/tagmaps/',
|
'/statuses/', '/emoji/', '/tags/', '/tagmaps/',
|
||||||
|
|
@ -43,7 +46,7 @@ def redirect_to_login_screen(self, calling_domain: str, path: str,
|
||||||
if string_ends_with(path, possible_endings):
|
if string_ends_with(path, possible_endings):
|
||||||
divert_to_login_screen = False
|
divert_to_login_screen = False
|
||||||
|
|
||||||
if divert_to_login_screen and not authorized:
|
if divert_to_login_screen:
|
||||||
divert_path = '/login'
|
divert_path = '/login'
|
||||||
if news_instance:
|
if news_instance:
|
||||||
# for news instances if not logged in then show the
|
# for news instances if not logged in then show the
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
__filename__ = "pwa.py"
|
__filename__ = "webapp_pwa.py"
|
||||||
__author__ = "Bob Mottram"
|
__author__ = "Bob Mottram"
|
||||||
__license__ = "AGPL3+"
|
__license__ = "AGPL3+"
|
||||||
__version__ = "1.7.0"
|
__version__ = "1.7.0"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue