-
Notifications
You must be signed in to change notification settings - Fork 328
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Location
File: packages/fuselage-ui-kit/src/blocks/VideoConferenceBlock/VideoConferenceBlock.tsx
Lines: 67–70
Problem
The openDiscussion function is attempting to call goToRoom(data.discussionRid) but the function goToRoom is not defined or imported in this component.
This causes a runtime ReferenceError when the "Open Discussion" button is clicked during a video conference.
Current Code:
const openDiscussion = () => {
if (data.discussionRid) {
goToRoom(data.discussionRid);
}
};
// Proposed Solution
// Import the correct navigation hook
import { useGoToRoom } from '@rocket.chat/ui-contexts';
const VideoConferenceBlock = ({ data }) => {
const goToRoom = useGoToRoom();
const openDiscussion = () => {
if (data.discussionRid) {
goToRoom(data.discussionRid); =
}
};
return (
// Component JSX here
);
};
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working