Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the ws properties and User-Agent header provided during client initialization for RemoteAuth #378

Merged
merged 2 commits into from
Oct 26, 2022

Conversation

connerdassen
Copy link
Contributor

With these changes RemoteAuth will use the same User-Agent header and WS properties as were provided in the Client options during initialization instead of picking a random User-Agent and using default WS properties.

@aiko-chan-ai
Copy link
Owner

@connerdassen RemoteAuth used in Client.QRLogin() can be used in other projects.
headers are the same as the browser, and Discord doesn't care about these headers 👍

@connerdassen
Copy link
Contributor Author

Discord does care about these headers for my purpose, they are used to identify the client type shown in the devices list that is currently in beta

@connerdassen
Copy link
Contributor Author

Client.QRLogin() also still works fine with my edits

@connerdassen
Copy link
Contributor Author

connerdassen commented Oct 26, 2022

I've made another commit for QRLogin to use the same user agent and ws properties as well, before it was still using a random UA and default ws properties.
There's no drawbacks to this as it will still fall back to a random UA and ws properties when they're not provided as options.

@aiko-chan-ai
Copy link
Owner

nice ❤️

@aiko-chan-ai aiko-chan-ai merged commit 83f9800 into aiko-chan-ai:main Oct 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants