Commit 9b1c224c authored by A. Koch's avatar A. Koch

add delete to uploads

parent 2ce1dd1a
Pipeline #1029 passed with stage
......@@ -32,6 +32,14 @@ class Uploads extends TinyEmitter {
})
})
})
app.delete('/uploads/:file', async (req, res) => {
upload.single('file')(req, res, async () => {
const minioClient = new Minio.Client(config.assets.client)
await minioClient.removeObject(config.assets.bucket, filename, req.params.file)
_this._response(req, res)
})
})
}
_response (req, res, data = {}) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment