The code outside the allotted editing area needed to be changed for my solution

Tell us what’s happening:
I had to change the code outside the allotted code editing area to pass this challenge. The brackets just outside of the code editing area needed to be wrapped in parentheses.

  **Your code so far**
const createPerson = (name, age, gender) => {
// Only change code below this line
return {
  name: name,
  age: age,
  gender: gender
// Only change code above this line

const createPerson = (name, age, gender) =>
 ({ name, age, gender });   
  **Your browser information:**

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 11_1_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.150 Safari/537.36.

Challenge: Write Concise Object Literal Declarations Using Object Property Shorthand

Link to the challenge:

You can, but you do not need to edit your code like this to pass. You just need to delete the propertyname: part of the given code.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.