Skip to content

Conversation

RRK1000
Copy link
Collaborator

@RRK1000 RRK1000 commented Oct 11, 2019

Creates a text file using the fs module. Text file contents are to be sent in the request body(req.body.text).

@RRK1000 RRK1000 requested a review from aniketnk October 11, 2019 13:54
res.status(500).send({ error: err });
}
console.log("File Created");
res.status(200).send({ success: true, message: "File Created." });
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of returning res, throw an error, or return an appropriate message. Also, please add an example of how to use this util.

@RRK1000
Copy link
Collaborator Author

RRK1000 commented Oct 20, 2019

Usage Example
image

The utilities return the object id of the uploaded file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants