petersirka / node-filestorage

Storage for storing uploaded files in node.js
MIT License
72 stars 12 forks source link

`Update` method doesn't work properly for custom attribute #25

Open yahortsaryk opened 6 years ago

yahortsaryk commented 6 years ago

Hi, thanks for your work, this is great package. I've found an annoying bug:

storage.update(id, fnCallback, [change]); method updates custom attribute for file metadata only, but doesn't update it for config file inside storage directory, which makes it impossible to search (find) by custom attribute. Steps to reproduce:

Result: I see new attribute in /000-000-001/000000005.data file but don't see it in /000-000-005/config