Extra reserved name

merge-requests/30/head
Bob Mottram 2021-02-25 18:33:35 +00:00
parent 307d386cc3
commit bcc59bac97
2 changed files with 3 additions and 2 deletions

View File

@ -10375,7 +10375,7 @@ class PubServer(BaseHTTPRequestHandler):
# redirect to the welcome screen
if htmlGET and authorized and usersInPath and \
not self.path.endswith('/welcome'):
'/welcome' not in self.path:
nickname = self.path.split('/users/')[1]
if '/' in nickname:
nickname = nickname.split('/')[0]

View File

@ -1273,7 +1273,8 @@ def _isReservedName(nickname: str) -> bool:
'likes', 'users', 'statuses', 'tags',
'accounts', 'channels', 'profile', 'u',
'updates', 'repeat', 'announce',
'shares', 'fonts', 'icons', 'avatars')
'shares', 'fonts', 'icons', 'avatars',
'welcome')
if nickname in reservedNames:
return True
return False