Skip to content

Commit

Permalink
Merge pull request #1839 from trumpet2012/patch-1
Browse files Browse the repository at this point in the history
[Docs] Update CRUD.md modifying database example
  • Loading branch information
radex authored Nov 20, 2024
2 parents 3da8820 + 842b1ca commit c554e67
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs-website/docs/docs/CRUD.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ All modifications to the database (like creating, updating, deleting records) mu

```js
await database.write(async () => {
const comment = await database.get('comments').find(commentId)
await comment.update(() => {
const someComment = await database.get('comments').find(commentId)
await someComment.update((comment) => {
comment.isSpam = true
})
})
Expand Down

0 comments on commit c554e67

Please sign in to comment.