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

Prevent duplicate accounts from logging in #1082

Merged
merged 2 commits into from
Jul 21, 2023
Merged

Conversation

MV-GH
Copy link
Collaborator

@MV-GH MV-GH commented Jul 21, 2023

Fixes #987

studio64_9HEnXRyEi4.mp4

I used name + instance to define duplicate because person.Id could be duplicate for two separate accounts on different instances.

I do feel like this whole login function with its numerous changeLemmyInstances should be refactored to use createTempInstance and only be swapped on login.

Copy link
Collaborator Author

@MV-GH MV-GH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How does this section prevent logging in with a non supported account?

             if (compareVersions(siteVersion, MINIMUM_API_VERSION) < 0) {
                        val message = ctx.resources.getString(
                            R.string.dialogs_server_version_outdated_short,
                            siteVersion,
                        )
                        Toast.makeText(ctx, message, Toast.LENGTH_SHORT).show()
                    }

Hmm this related #931 ?

@twizmwazin twizmwazin enabled auto-merge (squash) July 21, 2023 22:29
@twizmwazin twizmwazin merged commit a272431 into LemmyNet:main Jul 21, 2023
@MV-GH MV-GH deleted the bug/987 branch July 21, 2023 22:48
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.

Allows you to login with an already logged in account
2 participants