add group chat
This commit is contained in:
@@ -2,12 +2,9 @@ import { FC, useEffect, useState } from 'react';
|
||||
import { Modal } from '../../../../components/modal/Modal';
|
||||
import { PrimaryButton } from '../../../../components/button/PrimaryButton';
|
||||
import { SecondaryButton } from '../../../../components/button/SecondaryButton';
|
||||
import { Input } from '../../../../components/input/Input';
|
||||
import { useAppDispatch, useAppSelector } from '../../../../redux/hooks';
|
||||
import { createGroup } from '../../../../redux/slices/groups';
|
||||
import MarkdownEditor, { MarkDownPattern } from '../../../articleeditor/Editor';
|
||||
import {
|
||||
createPost,
|
||||
deletePost,
|
||||
fetchPostById,
|
||||
setGroupFeedStatus,
|
||||
@@ -55,7 +52,7 @@ const ModalUpdate: FC<ModalUpdateProps> = ({
|
||||
}, [statusDelete]);
|
||||
|
||||
useEffect(() => {
|
||||
dispatch(fetchPostById({ groupId, postId }));
|
||||
if (postId) dispatch(fetchPostById({ groupId, postId }));
|
||||
}, [postId]);
|
||||
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user