mirror of
https://github.com/codl/forget
synced 2025-01-22 11:54:09 +01:00
mastodon login: strip protocol
This commit is contained in:
parent
146dd263c9
commit
d7e1a7f179
@ -16,6 +16,7 @@ import version
|
||||
import lib.version
|
||||
import lib.settings
|
||||
import lib.json
|
||||
import re
|
||||
|
||||
|
||||
@app.before_request
|
||||
@ -275,6 +276,8 @@ def mastodon_login_step1(instance=None):
|
||||
generic_error='error' in request.args
|
||||
)
|
||||
|
||||
instance_url = re.sub('^https?://', '', instance_url,
|
||||
count=1, flags=re.IGNORECASE)
|
||||
instance_url = instance_url.split("@")[-1].lower()
|
||||
|
||||
callback = url_for('mastodon_login_step2',
|
||||
@ -349,6 +352,7 @@ def delete_reason():
|
||||
db.session.commit()
|
||||
return jsonify(status='success')
|
||||
|
||||
|
||||
@app.route('/api/badge/users')
|
||||
def users_badge():
|
||||
count = (
|
||||
|
Loading…
Reference in New Issue
Block a user