You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran into this issue when using a route to upload a file NSR was stripping out double quotes after parsing the body into request.post. After digging through, I found out that JSON.parse returns a string with the quotes stripped (it should either throw an error or return an object) even though the input is just a string. Please try the code below in console to replicate the error.
varstr='"hello"';console.log(JSON.parse(str));// returns hello removing the quotesvarstr='"hello';console.log(JSON.parse(str));// throws SynraxError exception as it should
The text was updated successfully, but these errors were encountered:
I ran into this issue when using a route to upload a file NSR was stripping out double quotes after parsing the body into request.post. After digging through, I found out that JSON.parse returns a string with the quotes stripped (it should either throw an error or return an object) even though the input is just a string. Please try the code below in console to replicate the error.
The text was updated successfully, but these errors were encountered: