gridfs-stream icon indicating copy to clipboard operation
gridfs-stream copied to clipboard

exist and remove causing trouble

Open AlexandreRoba opened this issue 7 years ago • 1 comments

Hi all,

Im' having difficulties with the following:

var mongo = require('mongodb');
var Grid = require('gridfs-stream');

var db = new mongo.Db('dbtest', new mongo.Server("127.0.0.1", 27017));
var gfs = Grid(db, mongo);
var filename = 'emptyfile.txt';
gfs.exist({filename}, (err, found)=> {
    if (err) {
        throw err;
    }
    console.log('File Exists:' + found);
});

It simply exit whitout any error or log. If I run it in debug it simply hang.

Any idea?

AlexandreRoba avatar Aug 23 '16 10:08 AlexandreRoba

{filename} » {filename: filename}

sergiu-gordienco avatar Aug 30 '16 15:08 sergiu-gordienco