Skip to content

Commit

Permalink
unique identifier for comments
Browse files Browse the repository at this point in the history
  • Loading branch information
judemont committed May 16, 2024
1 parent 25332bf commit 1d095f6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion scripts/loadComments.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ function loadComments(comments) {
for (let i = 0; i < comments.length; i++) {
commentsHtml += /*html*/ `
<div class="message">
<p class="user">39273</p>
<p class="user">USER#${comments[i].IP.match(/\d/g)
.join("")
.slice(0, 6)}:</p>
<p>${comments[i].content}</p>
</div>
`;
Expand Down

0 comments on commit 1d095f6

Please sign in to comment.