diff --git a/backend/app.py b/backend/app.py index ff72f47..9ec7641 100644 --- a/backend/app.py +++ b/backend/app.py @@ -360,7 +360,7 @@ def handle_connect(data): ## print("created") room_id = result[0] - + print(room_id) # join_room(room_id) socketio.emit("connection", {"data": room_id}) diff --git a/backend/test.jpg b/backend/test.jpg new file mode 100644 index 0000000..82f6cc8 Binary files /dev/null and b/backend/test.jpg differ diff --git a/frontend/src/components/Navbars/Sidebar/Sidebar.js b/frontend/src/components/Navbars/Sidebar/Sidebar.js index c642688..a1dcc66 100644 --- a/frontend/src/components/Navbars/Sidebar/Sidebar.js +++ b/frontend/src/components/Navbars/Sidebar/Sidebar.js @@ -66,7 +66,7 @@ const Sidebar = (props) => { to="/nft" icon="bi bi-currency-dollar" label="My NFT's" - /> */} + /> */} { }; const handleshare = async (reciever_id, msg) => { - socket.emit("connectuser", { sender_id: user_id, reciever_id: 2 }); + socket.emit("connectuser", { sender_id: user_id, reciever_id: reciever_id}); await socket.on("connection", (message) => { setroomid(message["data"]); }); diff --git a/frontend/src/components/posts/PostModal.js b/frontend/src/components/posts/PostModal.js index c1a5590..5206b2b 100644 --- a/frontend/src/components/posts/PostModal.js +++ b/frontend/src/components/posts/PostModal.js @@ -61,7 +61,7 @@ const PostModal = (props) => { const [loadcomments, setloadcomments] = useState(false); const [showOptions, setShowOptions] = useState(false); let element = props.element; - + console.log(element) let openPost = props.openPost; let handleClosePost = props.handleClosePost; let commentRef = useRef(); diff --git a/frontend/src/pages/ProfilePage.jsx b/frontend/src/pages/ProfilePage.jsx index 570bb8a..15fe6c7 100644 --- a/frontend/src/pages/ProfilePage.jsx +++ b/frontend/src/pages/ProfilePage.jsx @@ -61,11 +61,12 @@ const ProfilePage = (props) => { const getAllPosts = async () => { const { data } = await getuserposts(id); - if (data.sucess == false) { + if (data.sucess === false) { setposts([]); } setposts(data); - + + console.log(posts) }; const getFollowing = async () => { @@ -170,18 +171,18 @@ const ProfilePage = (props) => {
{posts.length > 0 ? ( - posts.map((post) => { + posts.map((postlist) => { return ( -
+
... @@ -191,7 +192,7 @@ const ProfilePage = (props) => { ) : (

Posts are empty

)} -
+