Make the file manager work a little more sanely with regard to paths.

This commit is contained in:
Dave Page
2016-06-17 17:12:04 +01:00
parent 1172e31019
commit 35243b9869
4 changed files with 7 additions and 22 deletions

View File

@@ -18,7 +18,7 @@ import config
def get_storage_directory():
if config.SERVER_MODE is not True:
return None
return '/'
storage_dir = getattr(
config, 'STORAGE_DIR',
@@ -30,7 +30,7 @@ def get_storage_directory():
)
if storage_dir is None:
return None
return '/'
username = current_user.email.split('@')[0]
if len(username) == 0 or username[0].isdigit():