Open flamingo-peacock opened 7 years ago
i have get the same problems!!!
I "solve" this problem using setTimeout.
Like this:
setTimeout(() => { Store.model('config').add(values).then((res) => { //Something }).catch(err => { console.log('Error ', err) }) }, 80)
Working here.
When I try to add things to my storage, it doesn't always add correctly, and many times just overwrites the last item, it doesn't give a new id, just keeps using the last one.
I was having this issue in another part of my app, where there was a race condition and the first call hadn't finished when the second one started, but that shouldn't be the case here, nor should that be an issue anyway. Storage should be able to handle items coming in rapid succession.
thoughts?