broker/matrix-mxid GET: local_mxid_for_email was async-def but never awaited — response contained a coroutine and FastAPI 500'd ('coroutine object is not iterable'), so the dashboard silently showed no registered Matrix ID. Make it a plain sync def (blocking urllib).
This commit is contained in:
1 parent
97ebe69553
commit
fd13bc6ea2
1 file changed
+1
-1
+1
-1
@@ -2708,7 +2708,7 @@ async def broker_get_matrix_mxid(request: Request):
|
|||||||
return {"matrix_mxid": get_member_matrix_mxid(email), "local_mxid": local_mxid_for_email(email)}
|
return {"matrix_mxid": get_member_matrix_mxid(email), "local_mxid": local_mxid_for_email(email)}
|
||||||
|
|
||||||
|
|
||||||
async def local_mxid_for_email(email: str) -> str:
|
def local_mxid_for_email(email: str) -> str:
|
||||||
"""Resolve a member's local Matrix ID (@username:inference.coop), or '' if unknown."""
|
"""Resolve a member's local Matrix ID (@username:inference.coop), or '' if unknown."""
|
||||||
import urllib.request
|
import urllib.request
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in new issue
Block a user