Hi for some reason this lesson is failing but my output is identical to the desired output. Even if I copy paste the solution in it still fails.
My code:
// Add your code below this line
var rating = watchList.map(x => ({
title: x["Title"],
rating: x["imdbRating"]
}));
// Add your code above this line
console.log(rating);
Output:
// running tests
ratings should equal [{"title":"Inception","rating":"8.8"},{"title":"Interstellar","rating":"8.6"},{"title":"The Dark Knight","rating":"9.0"},{"title":"Batman Begins","rating":"8.3"},{"title":"Avatar","rating":"7.9"}].
// tests completed
// console output
[{"title":"Inception","rating":"8.8"},{"title":"Interstellar","rating":"8.6"},{"title":"The Dark Knight","rating":"9.0"},{"title":"Batman Begins","rating":"8.3"},{"title":"Avatar","rating":"7.9"}]