Fixed JSON mime type for Safari.
rodzic
10b07270ed
commit
d85aed0c58
|
@ -42,6 +42,7 @@ router.post("/", upload, async (req, res) => {
|
|||
data.format = 'mastodon';
|
||||
break;
|
||||
case 'text/plain':
|
||||
case 'application/json':
|
||||
if (file.originalname.endsWith('.json')){
|
||||
const jsonData = JSON.parse(req.file.buffer.toString());
|
||||
data.outbox = jsonData;
|
||||
|
|
Ładowanie…
Reference in New Issue