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

A request to clarify a behavior related to upsert$ #71

Open
lilsweetcaligula opened this issue May 21, 2021 · 0 comments
Open

A request to clarify a behavior related to upsert$ #71

lilsweetcaligula opened this issue May 21, 2021 · 0 comments

Comments

@lilsweetcaligula
Copy link
Contributor

lilsweetcaligula commented May 21, 2021

I have code like this:

si.make('players')
  .data$({ id: 'MyPrecious', username: 'elvis', points: 9999 }) // => We are assuming the matching entity exists.
  .save$({ upsert$: ['username'] }, done)

Let's assume, a matching entity exists (i.e. there already exists a player with the username 'elvis'). What behavior should I expect?
Now let's assume, no matching entity exists. What behavior should I expect?

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

1 participant