fix(frontend): initialize follow state from server-side following list on remote actor profile
This commit is contained in:
@@ -17,14 +17,16 @@ interface RemoteUserProfileProps {
|
||||
actor: RemoteActor;
|
||||
initialPosts: Thought[];
|
||||
me: Me | null;
|
||||
initialFollowed?: boolean;
|
||||
}
|
||||
|
||||
export function RemoteUserProfile({
|
||||
actor,
|
||||
initialPosts,
|
||||
me,
|
||||
initialFollowed = false,
|
||||
}: RemoteUserProfileProps) {
|
||||
const [followed, setFollowed] = useState(false);
|
||||
const [followed, setFollowed] = useState(initialFollowed);
|
||||
const [loading, setLoading] = useState(false);
|
||||
const { token } = useAuth();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user