mirror of
https://github.com/tdurieux/anonymous_github.git
synced 2026-02-13 10:52:53 +00:00
feat: improve support for binary & audio files
This commit is contained in:
@@ -41,6 +41,8 @@ router.post("/", async (req: express.Request, res: express.Response) => {
|
||||
anonymizer.once("transform", (data) => {
|
||||
if (!mime && data.isText) {
|
||||
res.contentType("text/plain");
|
||||
} else if (!mime && !data.isText) {
|
||||
res.contentType("application/octet-stream");
|
||||
}
|
||||
});
|
||||
function handleStreamError(error: Error) {
|
||||
|
||||
Reference in New Issue
Block a user