mirror of https://gitlab.com/bashrc2/epicyon
Redirect to login screen
parent
e5f4807a6d
commit
c63912ed05
12
daemon.py
12
daemon.py
|
@ -10373,6 +10373,18 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
if '/users/' in self.path:
|
||||
usersInPath = True
|
||||
|
||||
# redirect to the welcome screen
|
||||
if htmlGET and authorized and usersInPath:
|
||||
nickname = self.path.split('/users/')[1]
|
||||
if '/' in nickname:
|
||||
nickname = nickname.split('/')[0]
|
||||
if '?' in nickname:
|
||||
nickname = nickname.split('?')[0]
|
||||
if not isWelcomeScreenComplete(self.server.baseDir,
|
||||
nickname,
|
||||
self.server.domain):
|
||||
self.path = '/users/' + nickname + '/welcome'
|
||||
|
||||
if not htmlGET and \
|
||||
usersInPath and self.path.endswith('/pinned'):
|
||||
nickname = self.path.split('/users/')[1]
|
||||
|
|
Loading…
Reference in New Issue