-
Notifications
You must be signed in to change notification settings - Fork 4
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
Duplicated entries when initializing multiple resources #5
Comments
ghost
mentioned this issue
Oct 11, 2019
ghost
pushed a commit
to fschrempf/lowdb-api
that referenced
this issue
Oct 11, 2019
See here for more information: rmariuzzo#5
ghost
pushed a commit
to fschrempf/slam.js
that referenced
this issue
Oct 11, 2019
See here for more information: rmariuzzo/lowdb-api#5.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
None yet
0 participants
I don't fully understand the reasons for this problem, but to me it looks like a bug in lowdb-api, lowdb or lodash. The steps to reproduce the issue are shown below.
The source of the problem seems to be here. The call to
db.defaults()
works fine the first time. But on the second run thedefaultResource
is not the default anymore, but contains the data for the first resource. The first call seems to have altereddefaultResource
, though I don't know why and how.A workaround is to inline the
defaultResource
into the call like this:Steps to reproduce:
artists
:rounds
:The text was updated successfully, but these errors were encountered: