aheckmann / gridfs-stream

Easily stream files to and from MongoDB
MIT License
615 stars 120 forks source link

exist ignores the root property #45

Closed mrzorg closed 10 years ago

mrzorg commented 10 years ago

You can insert: if( options.root ) return this.mongo.GridStore.exist(this.db, _id, options.root, callback);

before: return this.mongo.GridStore.exist(this.db, _id, callback);

trickeyone commented 10 years ago

I've run into the same problem. If you create an entry with a root property, if you need to check for its existence, you can't use GridFS's exist function. It's a small re-write, but still a bit of a hassle.

Reggino commented 10 years ago

Thanks for the report. This is a duplicate issue of #50 (where a fix is suggested), so i'm closing this one.