IndieAuth tweaks

This commit is contained in:
Thomas Sileo 2019-04-28 11:10:01 +02:00
parent 512f5dda33
commit d104290675
2 changed files with 4 additions and 4 deletions

4
app.py
View file

@ -2212,7 +2212,7 @@ def indieauth_endpoint():
session["logged_in"] = True
me = auth["me"]
state = auth["state"]
scope = " ".join(auth["scope"])
scope = auth["scope"].split()
print("STATE", state)
return build_auth_resp({"me": me, "state": state, "scope": scope})
@ -2235,7 +2235,7 @@ def token_endpoint():
)
if not auth:
abort(403)
scope = " ".join(auth["scope"])
scope = auth["scope"].split()
payload = dict(
me=me, client_id=client_id, scope=scope, ts=datetime.now().timestamp()
)

View file

@ -14,8 +14,8 @@
{% endif %}
<div style="flex:1;">
<div style="margin-top:20px">
<a style="font-size:1.2em;font-weight:600;text-decoration:none;color:#111;" href="{{ client.url }}">{{ client.name }}</a>
<p>wants you to login</p>
<a class="lcolor" style="font-size:1.2em;font-weight:600;text-decoration:none;" href="{{ client.url }}">{{ client.name }}</a>
<p>wants you to login as <strong class="lcolor">{{ me }}</strong></p>
</div>
</div>
</div>