jeromegn / Backbone.localStorage

A localStorage adapter for Backbone.js
MIT License
1.89k stars 681 forks source link

delete the model id from the records, not the model itself #229

Closed ciscou closed 3 years ago

ciscou commented 3 years ago

I've come across this bug that has been reported before, and looks like there are PRs trying to sove it, but given those PRs are kinda abandoned, I've thought I'd try myself too.

Thanks for having a look!

Closes #225

coveralls commented 3 years ago

Coverage Status

Coverage remained the same at 89.683% when pulling 8680314edecaf086b3dc0a48a805a20bf73e909b on ciscou:master into 560df91a82630e491cc225cb2c7e68ec77ef697e on jeromegn:master.

ciscou commented 3 years ago

I've had to change the travis configuration because the build was failing. If my solution is not OK just let me know :)

scott-w commented 3 years ago

Hey @ciscou I've just updated the comment to reference the bug. This all looks good.

Are you able to regenerate the localstorage code? If the change is relatively small, that would be awesome. I don't recall if I have access to the NPM (I'll need to check) but at least it gives people an option to load the script manually 😅

ciscou commented 3 years ago

Hey @scott-w thanks for having a look

I ran npm run package and pushed, I guess that's what you meant by "regenerate the code"? :)

If you can publish it to NPM that'd be awesome!