Skip to content

Commit

Permalink
fix: updated loading-boolean and added todo-comment
Browse files Browse the repository at this point in the history
  • Loading branch information
malmen237 committed Apr 9, 2024
1 parent 9772ee6 commit 87b61e8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/production-line/production-line.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export const ProductionLine: FC = () => {
const [participants, setParticipants] = useState<
{ name: string; sessionid: string }[] | null
>(null);
const [loading, setLoading] = useState<boolean>(false);
const [loading, setLoading] = useState<boolean>(true);

const { playbackState, audioElement } = useAudioElement({
audioContainerRef,
Expand Down Expand Up @@ -71,10 +71,10 @@ export const ProductionLine: FC = () => {
}, [navigate, joinProductionOptions]);

useEffect(() => {
setLoading(true);
if (connectionState === "connected") {
setLoading(false);
}
// TODO add handling for `connectionState === "failed"`
}, [connectionState]);

// TODO if (!input !output !username) return <JoinProductionForm />
Expand Down

0 comments on commit 87b61e8

Please sign in to comment.