title: TypeError: grid.mongo.GridStore is not a constructor
body: <p>I'm trying to use gridfs-stream to retrieve images I uploaded using multer. The following code is responding with <code>TypeError: grid.mongo.GridStore is not a constructor at new GridReadStream</code> Someone in <a href="https://stackoverflow.com/questions/69055292/error-grid-mongo-gridstore-is-not-a-consstructor-using-mongoose-grid-fs-strea">this</a> thread suggests that using a different mongoose version would solve the problem but I'm looking for a more sustainable solution.</p>
  <pre><code>const Grid = require(&quot;gridfs-stream&quot;);
  
  let gfs;
  //mongoose.Promise = global.Promise;
  const connection = mongoose.connection;
  connection.once('open', () =&gt; {
      gfs = Grid(connection.db, mongoose.mongo);
  })
  
  app.get(&quot;/files&quot;, async (req, res) =&gt; {
      try {
         //const file = await gfs.files.findOne({ filename: req.params.filename });
          const readStream = gfs.createReadStream({filename:'09ff76ee0d54433c1090117e479f679e.jpg'});
          readStream.pipe(res); 
      } catch (error) {
          console.log(error);
          res.send(error);
      }
  });
  </code></pre>
  <p>mongoose 6.0.11 ,
  gridfs-stream 1.1.1</p>