code: function createModel(optns = {}) {
    // ensure options
    let { connection, modelName, bucketName } = optns;
    connection = (connection || mongoose.connection);
    modelName = (_.isEmpty(modelName) ? DEFAULT_BUCKET_MODEL_NAME : modelName);
    bucketName = toCollectionName(modelName);
    bucketName =
      (modelName === DEFAULT_BUCKET_MODEL_NAME ? DEFAULT_BUCKET_NAME : bucketName);
  
    // create bucket
    const options =
      _.merge({}, { connection, modelName, bucketName }, optns);
    const bucket = createBucket(options);
  
    // construct model
    const schema = createSchema(bucket);
    const fileModel = model(modelName, schema, connection);
  
    // return model
    return fileModel;
  }
docs: @function createModel
  @name createModel
  @description Create GridFSBucket files collection model
  @param {Object} [optns] Optional settings.
  @param {Connection} [optns.connection = mongoose.connection] A valid instance
  of mongoose connection.
  @param {String} [optns.modelName="File"] Valid model name to use with
  mongoose
  @param {String} [optns.bucketName="fs"] The 'files' and 'chunks' collections
  will be prefixed with the bucket name followed by a dot.
  @param {Number} [optns.chunkSizeBytes=255 * 1024] Number of bytes stored in
  each chunk. Defaults to 255KB
  @param {Object} [optns.writeConcern] Optional write concern to be passed to
  write operations, for instance `{ w: 1 }`
  @param {Object} [optns.readPreference] Optional read preference to be passed
  to read operations
  @return {GridFSBucket} an instance of GridFSBucket
  @author lally elias <lallyelias87@mail.com>
  @since 1.0.0
  @version 0.1.0
  @public
  @static
  @example
  
  const File = createModel(); // => fs.files
  const Photo = createModel({ modelName }); // => photos.files
  const Photo = createModel({ modelName, connection }); // => photos.files