Commit fbf1334a authored by seoyeon's avatar seoyeon
Browse files

Merge remote-tracking branch 'origin/jaeyeoniiiiii' into seoyeon2

parents 6d3794cb 1f443ad8
......@@ -4,7 +4,6 @@ import roomApi from "../../apis/room.api";
import catchErrors from "../../context/catchError";
const userId = localStorage.getItem('user');
console.log(userId)
const INIT_ROOM = {
name: '',
owner: userId,
......
......@@ -4,7 +4,6 @@ import userApi from "../../apis/user.api";
import catchErrors from "../../context/catchError";
const userprofile = localStorage.getItem("user");
console.log(userprofile)
const INIT_USER = {
id: userprofile,
name: '',
......
......@@ -16,7 +16,6 @@ const Info = () => {
try {
const data = await userApi.getUser({id:userID});
setProfile(data);
console.log(data)
} catch (error) {}
}
useEffect(() => {
......
......@@ -3,7 +3,6 @@ import React, { useEffect, useState } from "react";
import userApi from "../../apis/user.api";
const userprofile = localStorage.getItem("user");
console.log(userprofile);
const INIT_PROFILE = {
id: userprofile,
name:"",
......@@ -22,7 +21,6 @@ const InfoUpdate = () => {
try {
const data = await userApi.getUser({ id: userID });
setProfile(data);
console.log(data);
} catch (error) {}
}
......@@ -37,7 +35,6 @@ const InfoUpdate = () => {
formData.append("id", userprofile);
try {
const res = await userApi.profileimg(formData);
console.log(res);
if(files){
setProfile({...profile, img:res})
}else{
......@@ -46,13 +43,11 @@ const InfoUpdate = () => {
};
const changeinfo = async (event) => {
console.log(profile);
const res = await userApi.updateinfo(profile)
};
const updateinfo = (event) => {
const { name, value } = event.target;
setProfile({ ...profile, [name]: value });
console.log(profile);
};
const{email,phone,name}=profile
......
......@@ -15,7 +15,6 @@ const Profile = () => {
async function getProfile(userID) {
try {
const data = await userApi.getUser({id:userID});
console.log(data.img)
setProfile(data.img)
} catch (error) {}
......@@ -26,7 +25,6 @@ const Profile = () => {
const { id } = useParams();
console.log(id);
return (
<div className="container" style={{ background: "#FCF4FF" }}>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment