Skip to content

[@types/mongodb] Missing error parameter in abort() callback for GridFSBucketWriteStream #44549

@alexy4744

Description

@alexy4744

Hi, this is a follow up issue for #44360. The callback definition for abort is missing an error parameter, which may be present if there was an error removing chunks.

https://mongodb.github.io/node-mongodb-native/3.6/api/GridFSBucketWriteStream.html#abort
https://mongodb.github.io/node-mongodb-native/3.6/api/GridFSBucket.html#~errorCallback
https://mongodb.github.io/node-mongodb-native/3.6/api/lib_gridfs-stream_upload.js.html#line112

const stream = bucket.openUploadStreamWithId(...);
stream.abort((error) => {});
Argument of type '(error: any) => void' is not assignable to parameter of type '() => void'.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions