expressjs / expressjs/multer

typeof [object Object] is string

Open
#726 2 comments 0 reactions 0 assignees View on GitHub
question
Dominant language
JavaScript
Stars
12.1k
Forks
1.1k
Avg merge
8d 2h
Merged PRs (30d)
21

Description

I need to upload several images along with some other data (strings, numbers, booleans and objects). However, the objects are parsed as strings "[object Object], [object Object]".
The rest of the fields and the image upload work well, but how do I retrieve the objects as objects? Does Multer only return strings?

```javascript
app.post('/adverts', requireAuth, upload.array('images', 15), Adverts.create);
```

index.js:
```javascript
app.use(bodyParser.json());
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.