Skip to content

Commit

Permalink
Update index.js
Browse files Browse the repository at this point in the history
  • Loading branch information
hchhabada authored Jul 10, 2023
1 parent 49666dd commit 10acb04
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -689,9 +689,8 @@ function parseData (request, state) {
state.body = state.body.substr(5);
}

state.body = decodeURIComponent(state.body);

if (request.headers['content-type'] === 'text/plain') {
state.body = decodeURIComponent(state.body);
return JSON.parse(state.body);
}

Expand Down

0 comments on commit 10acb04

Please sign in to comment.