From c9def5e1f10c51c5c3622755c1299500d13e267d Mon Sep 17 00:00:00 2001 From: Tarek <13603398+Taarek@users.noreply.github.com> Date: Tue, 23 Jun 2026 14:35:29 +0200 Subject: [PATCH] fix: Prevent app to poll status page on selfhosted (#1143) Co-authored-by: Jiralite <33201955+Jiralite@users.noreply.github.com> --- fluxer_app/src/features/user/state/StatusPage.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/fluxer_app/src/features/user/state/StatusPage.ts b/fluxer_app/src/features/user/state/StatusPage.ts index b27d7fe43..8f11a4d41 100644 --- a/fluxer_app/src/features/user/state/StatusPage.ts +++ b/fluxer_app/src/features/user/state/StatusPage.ts @@ -1,5 +1,6 @@ // SPDX-License-Identifier: AGPL-3.0-or-later +import RuntimeConfig from '@app/features/app/state/RuntimeConfig'; import {Logger} from '@app/features/platform/utils/AppLogger'; import {ExternalUrls} from '@fluxer/constants/src/ExternalUrls'; import {makeAutoObservable, runInAction} from 'mobx'; @@ -191,6 +192,7 @@ export class StatusPage { private checkInFlight: Promise | null = null; private lastCheckedAt = 0; private pollingStarted = false; + private readonly isSelfHosted = RuntimeConfig.isSelfHosted(); constructor() { makeAutoObservable( @@ -206,9 +208,10 @@ export class StatusPage { } startPolling(): void { - if (this.pollingStarted) { + if (this.isSelfHosted || this.pollingStarted) { return; } + this.pollingStarted = true; this.addResumeListeners(); this.schedulePoll(); @@ -236,6 +239,9 @@ export class StatusPage { } async checkIncidents(): Promise { + if (this.isSelfHosted) { + return; + } if (this.checkInFlight) { return this.checkInFlight; }