diff --git a/src/resources/editor.html b/src/resources/editor.html index a5a62da..9e3e7c8 100644 --- a/src/resources/editor.html +++ b/src/resources/editor.html @@ -94,23 +94,14 @@ content += "

The following articles will be cited:

\n"; for (var i = 0; i < citationList.length; i++) { citation = citationList[i][0].toString() + ". " + citationList[i][1]; - if (writtenArticles.some( - function (e) { - return (e.title === citationList[i][1]) && (e.author === player); - })) { - content += "

" + citation + " [Written by you!]

"; - } else if (writtenArticles.some( - function (e) { - return (e.title === citationList[i][1]); - })) { - content += "

" + citation + " [Written]"; - } else if (phantomArticles.some( - function (e) { - return (e.title === citationList[i][1]); - })) { - content += "

" + citation + " [Phantom]"; + if (writtenArticles.some(e => (e.title === citationList[i][1]) && (e.author === player))) { + content += "

" + citation + " [Written by you!]

"; + } else if (writtenArticles.some(e => (e.title === citationList[i][1]))) { + content += "

" + citation + " [Written]"; + } else if (phantomArticles.some(e => (e.title === citationList[i][1]))) { + content += "

" + citation + " [Phantom]"; } else { - content += "

" + citation + " [New]"; + content += "

" + citation + " [New]"; } content += "

\n"; }