Quote Web API (XMLHttpRequest)

I keep receiving a syntax error in the test responseReceivedHandler(). Line 19, column 26: SyntaxError: Unexpected token u in JSON at position 0

The fetchQuotes() function in quote.js is called with the selected topic and count when the Fetch Quotes button is clicked. Currently, fetchQuotes() displays example quotes in an ordered list inside the <div> with ID quotes.

Modify fetchQuotes() to use the XMLHttpRequest object to request quotes from the quote web API. Set the XMLHttpRequest‘s responseType to expect a JSON response.

Create a new function called responseReceivedHandler() that receives the XMLHttpRequest response and displays the quotes in an ordered list. Each quote should be followed by a space, a dash, a space, and the source.

Ex: If the user chooses “love” and “3” and presses Fetch Quotes, responseReceivedHandler() should place the returned quotes in an ordered list inside the <div>:

<div id="quotes">
   <ol>
      <li>If I know what love is, it is because of you. - Hermann Hesse</li>
      <li>The opposite of love is not hate, it's indifference. - Elie Wiesel</li>
      <li>Suffering passes, while love is eternal. - Laura Ingalls Wilder</li>
   </ol>
"use strict";
window.addEventListener("DOMContentLoaded", function () {
   document.querySelector("#fetchQuotesBtn").addEventListener("click", function () {

      // Get values from drop-downs
      const topicDropdown = document.querySelector("#topicSelection");
      const selectedTopic = topicDropdown.options[topicDropdown.selectedIndex].value;
      const countDropdown = document.querySelector("#countSelection");
      const selectedCount = countDropdown.options[countDropdown.selectedIndex].value;
   
      // Get and display quotes
      fetchQuotes(selectedTopic, selectedCount);       
   });
});

function fetchQuotes(topic, count) {
   const xhr = new XMLHttpRequest();
   xhr.open("GET", `https://wp.zybooks.com/quotes.php?topic=${topic}&count=${count}`);
   xhr.responseType = "json";
   xhr.addEventListener("load", responseReceivedHandler);
   xhr.send();
}

function responseReceivedHandler() {
   const response = JSON.parse(this.responseText);
   console.log(response); // log the response to the console
   let html = "";
   if (response.error) {
      html = response.error;
   } else {
      html = "<ol>";
      response.quotes.forEach(function (quote) {
         html += `<li>${quote.quote} - ${quote.source}</li>`;
      });
      html += "</ol>";
   }
   document.querySelector("#quotes").innerHTML = html;
}