[v3] fix: make AuthMe's Microsoft login-wall skip opt-in - #68
Open
monikon22 wants to merge 2 commits into
Open
Conversation
account.auth === 'microsoft' unconditionally skipped the login/register handshake, assuming AuthMe never prompts premium accounts. That's a server-config decision, not something derivable from the account type (issue Drownek#65: a microsoft account got prompted to /register like any other). Add skipOnMicrosoftAccount (default false) to opt back into the old shortcut once you've confirmed your server doesn't gate premium accounts.
README and the plugins.mdx example both stated it as fact; document skipOnMicrosoftAccount instead and fix the example hook.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related to #65.
onPlayerCreatehadif (account.auth === 'microsoft') return;, skipping the login/register handshake for every Microsoft account unconditionally. That assumed AuthMe never gates a premium account — a server-config decision, not something derivable fromaccount.auth. #65's log shows the opposite: amicrosoftaccount got prompted to/registerlike any offline one, and the plugin never answered it because it had already returned.Added
skipOnMicrosoftAccount(defaultfalse). With it off, Microsoft accounts now go through the same register/login/session-resumed poll as any other account, which means they need a password too —accounts { microsoft { ... } }never carries one (mineflayer authenticates the account itself; AuthMe is a separate wall). Set the plugin'spasswordoption for that, orskipOnMicrosoftAccount = trueonce you've confirmed a given server really does let premium accounts through without one.Also updated
README.mdand thedocs/plugins.mdxexample — both stated the old assumption as fact.