import React from "react"; import ProfileLink from "./ProfileLink"; import { Col } from "react-bootstrap"; import { Link } from "react-router-dom"; import { useSelector } from "react-redux"; const FriendList = (props) => { const { users, variant } = props; const allUsers = useSelector((state) => state.users); //Component is used with users prop in LikesModal, but without users prop in FriendsListPage let usersToUse = allUsers; if (users) usersToUse = users; const isModal = variant === "modal"; return (