不要怂,就是干,撸起袖子干!

Commit f25a59de by Dan Chung Committed by Sushant

docs(hooks): fix typo in bulk update example. (#8470)

1 parent 0a79ef81
Showing with 2 additions and 2 deletions
...@@ -239,7 +239,7 @@ Model.bulkCreate([ ...@@ -239,7 +239,7 @@ Model.bulkCreate([
Model.beforeBulkUpdate(({attributes, where}) => { Model.beforeBulkUpdate(({attributes, where}) => {
// where - in one of the fields of the clone of second argument sent to .update // where - in one of the fields of the clone of second argument sent to .update
// attributes - is one of the fields that the clone of second argument of .update would be extended with // attributes - is one of the fields that the clone of second argument of .update would be extended with
}) })
Model.update({gender: 'Male'} /*attributes argument*/, { where: {username: 'Tom'}} /*where argument*/) Model.update({gender: 'Male'} /*attributes argument*/, { where: {username: 'Tom'}} /*where argument*/)
...@@ -257,7 +257,7 @@ If you use `Model.bulkCreate(...)` with the `updatesOnDuplicate` option, changes ...@@ -257,7 +257,7 @@ If you use `Model.bulkCreate(...)` with the `updatesOnDuplicate` option, changes
```js ```js
// Bulk updating existing users with updatesOnDuplicate option // Bulk updating existing users with updatesOnDuplicate option
Users.bulkCreate([ Users.bulkCreate([
{ id: 1, isMemeber: true }, { id: 1, isMember: true },
{ id: 2, isMember: false } { id: 2, isMember: false }
], { ], {
updatesOnDuplicate: ['isMember'] updatesOnDuplicate: ['isMember']
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!