Skip to content

Fix destructuring#17

Open
matthew1232 wants to merge 1 commit intowalmat:es6-rewritefrom
matthew1232:patch-17
Open

Fix destructuring#17
matthew1232 wants to merge 1 commit intowalmat:es6-rewritefrom
matthew1232:patch-17

Conversation

@matthew1232
Copy link
Copy Markdown

Convert body to JSON, add body parameter to errors, fix destructuring

Convert body to JSON, add body parameter to errors, fix destructuring
const { PortfolioItem: { chainId, skuUuid } } = body;
return { chainId, skuUuid };
const body = JSON.parse(res.body);
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as the other PR. I'm not sure the JSON.parse() is needed. Please correct me if I'm wrong!


const { body } = res;
const { PortfolioItem: { chainId, skuUuid } } = body;
const body = JSON.parse(res.body);
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here too


const { body } = res;
const { PortfolioItem: { chainId, skuUuid } } = body;
const body = JSON.parse(res.body);
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants