OAuth - /Authorize endpoint returns 303 instead of 302

We’re integrating Hugging Face OAuth into our website and have encountered an issue with the /authorize endpoint. It’s currently returning a 303 status code, which leads to the loss of the original window object during the redirect process post-authorization on Hugging Face’s site. This behavior complicates the implementation of a seamless popup OAuth component, as we’re unable to programmatically close the authentication tab upon completion. We’ve noticed that this issue affects the functionality of OAuth libraries like react-use-oauth2, which are designed to operate with a persistent window object.

Would it be possible to adjust the /authorize endpoint to return a 302 status instead? This change could maintain the window object’s continuity and greatly facilitate the integration of popup OAuth flows.