Skip to content

Commit 5c4d360

Browse files
authored
change based on comment
1 parent 8d388c5 commit 5c4d360

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Sprint-3/quote-generator/quotes.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -496,16 +496,16 @@ const quotes = [
496496

497497
// call pickFromArray with the quotes array to check you get a random quote
498498
let randomQuote = pickFromArray(quotes);
499-
console.log(randomQuote); // maybe logs { quote: "...", author: "..." }
499+
500500

501501
const quoteElement = document.getElementById("quote");
502502
const authorElement = document.getElementById("author");
503503
const newquoteButton = document.getElementById("new-quote");
504504

505505
function displayRandomQuote() {
506506
const randomQuote = pickFromArray(quotes);
507-
quoteElement.innerText = `"${randomQuote.quote}"`;
508-
authorElement.innerText = `- ${randomQuote.author}`;
507+
quoteElement.textContent = `"${randomQuote.quote}"`;
508+
authorElement.textContent = `- ${randomQuote.author}`;
509509
}
510510
displayRandomQuote();
511511
newquoteButton.addEventListener("click", displayRandomQuote);

0 commit comments

Comments
 (0)