Skip to content

Commit

Permalink
Merge pull request #595 from namore/add_warning_foreach_keys
Browse files Browse the repository at this point in the history
Update README.md
  • Loading branch information
benbjohnson committed Sep 13, 2016
2 parents 9dffd9d + 1e271f5 commit fff57c1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,10 @@ db.View(func(tx *bolt.Tx) error {
})
```

Please note that keys and values in `ForEach()` are only valid while
the transaction is open. If you need to use a key or value outside of
the transaction, you must use `copy()` to copy it to another byte
slice.

### Nested buckets

Expand Down

0 comments on commit fff57c1

Please sign in to comment.