After a successful Oauth flow, Twitch seems to be redirecting to https://id.twitch.tv (no extra path or query params) and not the root path of my app as it should.

This happens only on 2 of the 3 sign in buttons. One of them redirects ok.
After a few hours of debugging, I can’t find why 2 out of the 3 buttons are triggering this failed redirect, since they generate exactly the same Oauth URL:
https://id.twitch.tv/oauth2/authorize?client_id=<hidden>&redirect_uri=https%3A%2F%2Fwww.framedrop.co%2Fusers%2Fauth%2Ftwitch%2Fcallback&response_type=code&scope=user%3Aread%3Aemail&state=<hidden>
Does anyone have an idea of where to look to track this bug?
Thanks!