Closed Johennes closed 2 months ago
Link to problem area:
https://spec.matrix.org/v1.11/client-server-api/#login-fallback
Issue
The fallback login specification mentions a function that is called when login is completed.
The page will attempt to call the JavaScript function window.onLogin when login has been successfully completed.
window.onLogin
It does, however, not specify what parameters the function is called with, if any.
Synapse appears to pass in the response body of the POST /login request parsed from JSON into a JavaScript object by jQuery.
POST /login
$.post(matrixLogin.endpoint, JSON.stringify(data), function(response) { ... matrixLogin.onLogin(response); })
Dendrite has copied Synapse's behavior.
On the client-side, element-ios, for instance, depends on this behavior and parses the passed argument to a login response.
Similar to the argument made in https://github.com/matrix-org/matrix-spec/issues/640#issuecomment-2209163225, I suspect this is simply a spec omission that we can fix without an MSC?
I think if that is what synapse has always done since implementing this then we can just clarify the spec.
Link to problem area:
https://spec.matrix.org/v1.11/client-server-api/#login-fallback
Issue
The fallback login specification mentions a function that is called when login is completed.
It does, however, not specify what parameters the function is called with, if any.
Synapse appears to pass in the response body of the
POST /login
request parsed from JSON into a JavaScript object by jQuery.Dendrite has copied Synapse's behavior.
On the client-side, element-ios, for instance, depends on this behavior and parses the passed argument to a login response.
Similar to the argument made in https://github.com/matrix-org/matrix-spec/issues/640#issuecomment-2209163225, I suspect this is simply a spec omission that we can fix without an MSC?