Skip to content

Take control over your live stream video by running it yourself. Streaming + chat out of the box.

Use hook properly when doing upgrade check

Gabe Kangasb647e7d5758c
diff --git a/web/components/main-layout.tsx b/web/components/main-layout.tsx
index 0c4563e802..aed1b1f239 100644
--- a/web/components/main-layout.tsx
+++ b/web/components/main-layout.tsx
@@ -30,8 +30,6 @@ import { TEXTFIELD_PROPS_STREAM_TITLE } from '../utils/config-constants';
import { UpdateArgs } from '../types/config-section';
-let performedUpgradeCheck = false;
-
export default function MainLayout(props) {
const { children } = props;
@@ -60,11 +58,8 @@ export default function MainLayout(props) {
};
useEffect(() => {
- if (!performedUpgradeCheck) {
- checkForUpgrade();
- performedUpgradeCheck = true;
- }
- });
+ checkForUpgrade();
+ }, [versionNumber]);
useEffect(() => {
setCurrentStreamTitle(instanceDetails.streamTitle);