Combination of filter and map is not getting accepted by FCC editor

wrt chapter Functional Programming: Use the filter Method to Extract Data from an Array,

I’ve used below solution

var filteredList = watchList.filter( object => object.imdbRating >= 8.0).
map(object => ({ “title” : object[“Title”], “Rating” : object[“imdbRating”] }) );

But FCC editor is not accepting above solution. I checked hint which is as below

var filteredList = {
  return {title: e["Title"], rating: e["imdbRating"]}
}).filter((e) => e.rating >= 8);

Please clarify what is wrong with my solution ?


There are a few things missing to be able to help you

  1. What is your whole code?
  2. What does your code returns?
  3. What do you think is the issue?

Also, when you need help with a challenge you will have help sooner if you use the “Ask for help” button and post in that category (for example for your question in the #javascript category)

Your code returns objects of the form { title: string, Rating: string }.

The challenge requires objects of the form { title: string, rating: string }.

When I clicked on Ask for help button getting 414 error. please check attachment.

@lionel-rowe thanks for pointing out mistake, it was silly mistake on my end.