Skip to content

Commit

Permalink
Merge pull request #125 from Hanjuri/feature/#49
Browse files Browse the repository at this point in the history
fix:채팅방 수정
  • Loading branch information
Hanjuri authored Sep 10, 2024
2 parents b059e96 + fd4aae5 commit 8d393cc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/pages/PeopleListPage/PeopleListPage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import { useNavigate } from "react-router-dom";
import Layout from "../../components/Common/Layout.jsx";
import MiniLayout from "../../components/Common/miniLayout.jsx";
import PeopleCard from "../../components/PeopleListComponents/PeopleCard/peopleCard.jsx";
import fetchMembersList from "../../services/fetchMembersList.js";
import dummyImages1 from "../../assets/dummyImages/peopleList.jpeg"
import { PeopleListCall } from "../../api/PeopleListCall.js"; // PeopleListCall 불러오기
import dummyImages1 from "../../assets/dummyImages/peopleList.jpeg";

export const PeopleListPage = () => {
const navigate = useNavigate();
Expand All @@ -16,7 +16,8 @@ export const PeopleListPage = () => {
const displayMembers = async () => {
setIsLoading(true);
try {
const membersData = await fetchMembersList();
// fetchMembersList 대신 PeopleListCall 사용
const membersData = await PeopleListCall();
console.log('Fetched Members:', membersData.data); // 데이터 구조를 확인하기 위해 콘솔에 출력
if (membersData && membersData.data && membersData.data.memberList) {
setMembers(membersData.data.memberList);
Expand All @@ -34,7 +35,6 @@ export const PeopleListPage = () => {

displayMembers();
}, []);
;

const handleCardClick = () => {
navigate('/details');
Expand All @@ -58,4 +58,4 @@ export const PeopleListPage = () => {
</MiniLayout>
</Layout>
);
};
};
1 change: 1 addition & 0 deletions src/pages/chat/ChatMain.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ function ChatMain() {


useEffect(() => {
console.log(nowUser,'현재 사용자')
const fetchChatList = async () => {
try {
const response = await getChatList(nowUser);
Expand Down

0 comments on commit 8d393cc

Please sign in to comment.