Allow static resources without basic auth

This commit is contained in:
Micah Lee 2019-05-22 20:15:49 -07:00
parent 41be429b91
commit 7ac81e6b7e
No known key found for this signature in database
GPG Key ID: 403C2657CD994F73

View File

@ -142,6 +142,11 @@ class Web(object):
@self.app.before_request
def conditional_auth_check():
# Allow static files without basic authentication
if(request.path.startswith(self.static_url_path + '/')):
return None
# If public mode is disabled, require authentication
if not self.common.settings.get('public_mode'):
@self.auth.login_required
def _check_login():