fix: unique key in message list

This commit is contained in:
fryorcraken.eth 2022-09-02 14:14:28 +10:00
parent 491062154b
commit e4c001d901
No known key found for this signature in database
GPG Key ID: A82ED75A8DFC50A4
1 changed files with 4 additions and 6 deletions

View File

@ -16,12 +16,10 @@ export default function ChatList(props: Props) {
const renderedMessages = props.messages.map((message) => (
<LiveMessage
key={
message.sentTimestamp
? message.sentTimestamp.valueOf()
: "" +
message.timestamp.valueOf() +
message.nick +
message.payloadAsUtf8
message.nick +
message.payloadAsUtf8 +
message.timestamp.valueOf() +
message.sentTimestamp?.valueOf()
}
authorName={message.nick}
date={formatDisplayDate(message)}