feat: Adds id to chat messages internal state.

This commit is contained in:
Дамян Минков 2021-12-22 10:17:53 -06:00
parent f2efdfcbc1
commit 6159504478
1 changed files with 2 additions and 0 deletions

View File

@ -10,6 +10,7 @@ import {
SET_PRIVATE_MESSAGE_RECIPIENT,
SET_IS_POLL_TAB_FOCUSED
} from './actionTypes';
import { v4 as uuidv4 } from 'uuid';
const DEFAULT_STATE = {
isOpen: false,
@ -29,6 +30,7 @@ ReducerRegistry.register('features/chat', (state = DEFAULT_STATE, action) => {
error: action.error,
id: action.id,
isReaction: action.isReaction,
messageId: uuidv4(),
messageType: action.messageType,
message: action.message,
privateMessage: action.privateMessage,