gridfs-extra

Home > gridfs-extra > getGridFSBucketDb

getGridFSBucketDb() function

getGridFSBucketDb returns mongodb Db instance which is used to create this bucket.

this not a wrapper of mongodb public native api, so use this method carefully

Signature:

declare function getGridFSBucketDb(bucket: mongodb.GridFSBucket): mongodb.Db;

Parameters

Parameter Type Description
bucket mongodb.GridFSBucket a mongodb gridFS bucket

Returns:

mongodb.Db

mongodb Db instance