Skip to content

Cannot modify user error when using _linkWith google auth on an existing user.. #5148

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

Closed
mikecann opened this issue Oct 27, 2018 · 8 comments

Comments

@mikecann
Copy link

Issue Description

I am following this part of the JS SDK docs:

https://docs.parseplatform.org/js/guide/#linking-1

When you attempt to do that with google auth and an existing user however you end up with the following error:

error: Cannot modify user JzDZZ4XjW5. ParseError: 206 Cannot modify user JzDZZ4XjW5.

I suspect this happens with facebook auth too.

Steps to reproduce

  1. create a new user manually with username and password.
  2. logout
  3. attempt to social-auth login with using google following the guide here: https://docs.parseplatform.org/js/guide/#linking-1

Expected Results

_linkWith should be able to modify the existing user and add the new google auth data.

Actual Outcome

error: Cannot modify user JzDZZ4XjW5.

Environment Setup

  • Server
    • parse-server version: 3.1.0
    • Operating System: Windows 10 64
    • Hardware:
    • Localhost or remote server? (AWS, Heroku, Azure, Digital Ocean, etc): Local

Logs/Trace

@stale
Copy link

stale bot commented Dec 11, 2018

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

1 similar comment
@stale
Copy link

stale bot commented Jan 25, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jan 25, 2019
@stale stale bot closed this as completed Feb 1, 2019
@ashish-naik
Copy link

@mikecann Were you able to resolve this issue?

@mikecann
Copy link
Author

@mikecann Were you able to resolve this issue?

No idea mate. Cant remember. Ditched parse a while back.

@2shrestha22
Copy link

@mikecann I am searching for same issue. I want to automatically link user when signing with OAuth providers but didn't find any solution yet.

@mtrezza
Copy link
Member

mtrezza commented May 23, 2021

@ashish-naik @2shrestha22 If you are experiencing an issue, please open a new issue (because there is a new issue template) and paste your code and describe the issue. Ideally, you could in addition submit a failing test case to demonstrate the issue. I would expect that existing tests already cover the case of linking an existing user, so a look into the tests may be worthwhile.

Note that we have since deactivated the stale bot to make sure we manually review every issue and close only if an outcome is reached, but not because of staleness anymore. Apologies to @mikecann that there was no reaction to this issue here.

@2shrestha22
Copy link

@mtrezza, Thank you! It is not issue with Parse but actually with me (or others) unable to find how to make things work. In parse documentation I found cloud code should be used to link unauthenticated user, but being a noob and not knowing JS, things are terribly complicated. It will be nice if I get some help on creating cloud code to automatically link existing user when login with 3rd party auth like google, facebook.

@mtrezza
Copy link
Member

mtrezza commented May 23, 2021

@2shrestha22 Thanks for clarifying. If you need code level support, I suggest you open a topic in the community forum. Then, once you found out how to do it with the help of others, please feel free to suggest an improvement to the docs by opening an issue in the docs repo.

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

No branches or pull requests

4 participants