mirror of
https://github.com/cwinfo/powerdns-admin.git
synced 2024-11-08 14:40:27 +00:00
Force loading gravatar over https
This commit is contained in:
parent
ee033f2198
commit
e7a4fb5e6a
@ -150,5 +150,4 @@ def pdns_api_extended_uri(version):
|
||||
|
||||
def email_to_gravatar_url(email, size=100):
|
||||
hash_string = hashlib.md5(email).hexdigest()
|
||||
schema = 'https' if app.config['SSL'] else 'http'
|
||||
return "%s://s.gravatar.com/avatar/%s?s=%s" % (schema, hash_string, size)
|
||||
return "https://s.gravatar.com/avatar/%s?s=%s" % (hash_string, size)
|
||||
|
@ -69,9 +69,6 @@ def before_request():
|
||||
g.user = current_user
|
||||
login_manager.anonymous_user = Anonymous
|
||||
|
||||
# set website SSL status
|
||||
app.config['SSL'] = True if request.is_secure else False
|
||||
|
||||
|
||||
@login_manager.user_loader
|
||||
def load_user(id):
|
||||
|
Loading…
Reference in New Issue
Block a user