<% messages.forEach(message=>{ %>
<% if (message){ %>
<%=new Date(message.time).toLocaleString() %>
<%= message.content %>
<% if (user){ %>
<% if (!message.deleted){ %>
<% } else { %>
This message has been deleted
<% }; %>
<%= message.reactCount %>
<% } %>
<% } else { %>
DELETED MESSAGE
<% } %>
<% }); %>