Skip to content

A free and open source instant messaging and VoIP chat app built for friends, groups, and communities.

TypeScript fluxerfluxerapp

refactor(app): unexport platform values, tidy token selection

Hampusd2867e529198
diff --git a/fluxer_app/src/features/app/components/layout/UserAreaState.ts b/fluxer_app/src/features/app/components/layout/UserAreaState.ts
index 328ea59cc..73ac3422c 100644
--- a/fluxer_app/src/features/app/components/layout/UserAreaState.ts
+++ b/fluxer_app/src/features/app/components/layout/UserAreaState.ts
@@ -2,7 +2,7 @@
export type UserAreaMuteReason = 'guild' | 'voice_push_to_talk' | 'self' | 'permission' | null;
-export interface UserAreaMicrophoneSignals {
+interface UserAreaMicrophoneSignals {
effectiveAudioMuted: boolean;
effectiveAudioDeafened: boolean;
isGuildMuted: boolean;
diff --git a/fluxer_app/src/features/app/components/skeleton/SkeletonSurfaceContract.ts b/fluxer_app/src/features/app/components/skeleton/SkeletonSurfaceContract.ts
index 3b63f7435..fa1be59c7 100644
--- a/fluxer_app/src/features/app/components/skeleton/SkeletonSurfaceContract.ts
+++ b/fluxer_app/src/features/app/components/skeleton/SkeletonSurfaceContract.ts
@@ -168,7 +168,7 @@ export const SKELETON_SURFACE_TOKENS = [
export type SkeletonSurfaceToken = (typeof SKELETON_SURFACE_TOKENS)[number];
-export const SKELETON_INJECTED_TOKENS = [
+const SKELETON_INJECTED_TOKENS = [
'--active-now-participant-outline',
'--active-now-participant-overlap',
'--active-now-participant-size',
diff --git a/fluxer_app/src/features/app/config/Config.ts b/fluxer_app/src/features/app/config/Config.ts
index 12ab7a113..b3532ed59 100644
--- a/fluxer_app/src/features/app/config/Config.ts
+++ b/fluxer_app/src/features/app/config/Config.ts
@@ -9,7 +9,7 @@ const buildInfoSchema = v.object({
class BuildInfoInvariantError extends Error {
constructor(issues: string) {
super(
- `Invalid build info: ${issues}. PUBLIC_BUILD_VERSION and PUBLIC_RELEASE_CHANNEL are injected by rspack at build time and by fluxer_app/vitest.config.ts test.env under test. PUBLIC_RELEASE_CHANNEL must be stable, canary or development.`,
+ `Invalid build info: ${issues}. PUBLIC_BUILD_VERSION and PUBLIC_RELEASE_CHANNEL are injected by rspack at build time. PUBLIC_RELEASE_CHANNEL must be stable, canary or development.`,
);
this.name = 'BuildInfoInvariantError';
}
diff --git a/fluxer_app/src/features/app/hooks/useConnectionNotice.ts b/fluxer_app/src/features/app/hooks/useConnectionNotice.ts
index 36468df5f..e091dcbb8 100644
--- a/fluxer_app/src/features/app/hooks/useConnectionNotice.ts
+++ b/fluxer_app/src/features/app/hooks/useConnectionNotice.ts
@@ -19,7 +19,7 @@ export const ConnectionNoticeTone = Object.freeze({
export type ConnectionNoticeTone = (typeof ConnectionNoticeTone)[keyof typeof ConnectionNoticeTone];
-export interface ConnectionNoticeAction {
+interface ConnectionNoticeAction {
readonly label: string;
readonly url: string;
}
diff --git a/fluxer_app/src/features/app/state/GeoIP.ts b/fluxer_app/src/features/app/state/GeoIP.ts
index ab6e28125..a89e7f031 100644
--- a/fluxer_app/src/features/app/state/GeoIP.ts
+++ b/fluxer_app/src/features/app/state/GeoIP.ts
@@ -10,7 +10,7 @@ import {compareStructural, makeAutoObservable, reaction, runInAction} from 'mobx
const logger = new Logger('GeoIP');
const RESOLVE_TIMEOUT_MS = 5000;
-export type GeoIPResolution = 'pending' | 'resolved' | 'unavailable';
+type GeoIPResolution = 'pending' | 'resolved' | 'unavailable';
interface ConnectionGeo {
countryCode: string | null;
diff --git a/fluxer_app/src/features/app/utils/LimitResolverAdapter.ts b/fluxer_app/src/features/app/utils/LimitResolverAdapter.ts
index 391015c52..955b0839a 100644
--- a/fluxer_app/src/features/app/utils/LimitResolverAdapter.ts
+++ b/fluxer_app/src/features/app/utils/LimitResolverAdapter.ts
@@ -8,7 +8,7 @@ import type {LimitKey} from '@fluxer/constants/src/LimitConfigMetadata';
import {resolveLimit} from '@fluxer/limits/src/LimitResolver';
import type {LimitConfigSnapshot} from '@fluxer/limits/src/LimitTypes';
-export interface LimitResolveOptions {
+interface LimitResolveOptions {
key: LimitKey;
fallback: number;
context?: LimitContextInput;
diff --git a/fluxer_app/src/features/platform/URLOriginUtils.ts b/fluxer_app/src/features/platform/URLOriginUtils.ts
index dfdc2bd59..bc7e26872 100644
--- a/fluxer_app/src/features/platform/URLOriginUtils.ts
+++ b/fluxer_app/src/features/platform/URLOriginUtils.ts
@@ -1,6 +1,6 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
-export function resolveURLFromRoot(input: string | URL, reference: string | URL): URL {
+function resolveURLFromRoot(input: string | URL, reference: string | URL): URL {
return new URL(input, new URL('/', reference));
}
diff --git a/fluxer_app/src/features/platform/components/loadable/LoadableComponent.tsx b/fluxer_app/src/features/platform/components/loadable/LoadableComponent.tsx
index 57ed5c8f0..d9810e5f6 100644
--- a/fluxer_app/src/features/platform/components/loadable/LoadableComponent.tsx
+++ b/fluxer_app/src/features/platform/components/loadable/LoadableComponent.tsx
@@ -21,7 +21,7 @@ export interface LoadableErrorProps {
retry: () => void;
}
-export interface LoadableModule<Props extends object> {
+interface LoadableModule<Props extends object> {
default: ComponentType<Props>;
}
@@ -29,7 +29,7 @@ export type LoadableComponent<Props extends object> = ComponentType<Props> & {
preload: () => Promise<boolean>;
};
-export interface CreateLoadableComponentOptions<Props extends object> {
+interface CreateLoadableComponentOptions<Props extends object> {
displayName: string;
load: () => Promise<LoadableModule<Props>>;
LoadingComponent?: ComponentType;
@@ -100,7 +100,7 @@ function LoadableInlineLoadError({error, retry}: LoadableErrorProps): React.JSX.
);
}
-export function createLoadableComponent<Props extends object>({
+function createLoadableComponent<Props extends object>({
displayName,
load,
LoadingComponent = NullLoadingComponent,
diff --git a/fluxer_app/src/features/platform/state/AccountScopedWork.ts b/fluxer_app/src/features/platform/state/AccountScopedWork.ts
index 93871c72e..3abfc850e 100644
--- a/fluxer_app/src/features/platform/state/AccountScopedWork.ts
+++ b/fluxer_app/src/features/platform/state/AccountScopedWork.ts
@@ -23,9 +23,9 @@ export const AccountScopedWorkTransitionReason = Object.freeze({
export type AccountScopedWorkTransitionReason =
(typeof AccountScopedWorkTransitionReason)[keyof typeof AccountScopedWorkTransitionReason];
-export type AccountScopedWorkCancellation = (reason: AccountScopedWorkTransitionReason) => void | Promise<void>;
+type AccountScopedWorkCancellation = (reason: AccountScopedWorkTransitionReason) => void | Promise<void>;
-export interface AccountScopedWorkTransitionHandler {
+interface AccountScopedWorkTransitionHandler {
suspend(reason: AccountScopedWorkTransitionReason): void | Promise<void>;
resume(reason: AccountScopedWorkTransitionReason): void | Promise<void>;
released?(reason: AccountScopedWorkTransitionReason): void | Promise<void>;
diff --git a/fluxer_app/src/features/platform/state/AppStorageBootstrap.ts b/fluxer_app/src/features/platform/state/AppStorageBootstrap.ts
index a446577e3..bc1bfc147 100644
--- a/fluxer_app/src/features/platform/state/AppStorageBootstrap.ts
+++ b/fluxer_app/src/features/platform/state/AppStorageBootstrap.ts
@@ -10,7 +10,6 @@ import {Logger} from '@app/features/platform/utils/AppLogger';
export type {
AppStorageBootstrapHandle,
- AppStorageFinalizationResult,
AppStorageSessionAccount,
} from '@app/features/platform/state/AppStorageBootstrapContract';
diff --git a/fluxer_app/src/features/platform/state/AppStorageBroadcast.ts b/fluxer_app/src/features/platform/state/AppStorageBroadcast.ts
index 00c99ba67..534040125 100644
--- a/fluxer_app/src/features/platform/state/AppStorageBroadcast.ts
+++ b/fluxer_app/src/features/platform/state/AppStorageBroadcast.ts
@@ -32,7 +32,7 @@ interface LockManagerLike {
request<T>(name: string, callback: () => Promise<T>): Promise<T>;
}
-export class AppStorageLockUnavailableError extends Error {
+class AppStorageLockUnavailableError extends Error {
public constructor(name: string, options?: ErrorOptions) {
super(`Web Locks could not serialise app storage operation ${name}`, options);
this.name = 'AppStorageLockUnavailableError';
diff --git a/fluxer_app/src/features/platform/state/AppStorageDesktopAuthority.ts b/fluxer_app/src/features/platform/state/AppStorageDesktopAuthority.ts
index c082a6244..bed2b5e50 100644
--- a/fluxer_app/src/features/platform/state/AppStorageDesktopAuthority.ts
+++ b/fluxer_app/src/features/platform/state/AppStorageDesktopAuthority.ts
@@ -58,7 +58,7 @@ export interface DesktopStorageImport {
readonly candidate: DesktopStorageAuthorityCandidate | null;
}
-export class DesktopStorageAuthorityUnavailableError extends Error {
+class DesktopStorageAuthorityUnavailableError extends Error {
public constructor(message: string, options?: ErrorOptions) {
super(message, options);
this.name = 'DesktopStorageAuthorityUnavailableError';
@@ -224,7 +224,7 @@ async function verifyDesktopSession(
}
}
-export class DesktopStorageAuthorityCandidate {
+class DesktopStorageAuthorityCandidate {
private constructor(
public readonly request: DesktopLegacyImportRequest,
public readonly result: DesktopLegacyImportResult,
diff --git a/fluxer_app/src/features/platform/state/ClientInstallationId.ts b/fluxer_app/src/features/platform/state/ClientInstallationId.ts
index e71fbf662..e996866f8 100644
--- a/fluxer_app/src/features/platform/state/ClientInstallationId.ts
+++ b/fluxer_app/src/features/platform/state/ClientInstallationId.ts
@@ -2,7 +2,7 @@
import {readRawStorageItem, writeRawStorageItem} from '@app/features/platform/state/PrebootMirror';
-export const CLIENT_INSTALLATION_ID_STORAGE_KEY = 'ClientInstallationId';
+const CLIENT_INSTALLATION_ID_STORAGE_KEY = 'ClientInstallationId';
const CLIENT_INSTALLATION_ID_PATTERN = /^[0-9a-f]{32}$/;
const CLIENT_INSTALLATION_ID_BYTE_LENGTH = 16;
diff --git a/fluxer_app/src/features/platform/state/DesktopLegacyImport.ts b/fluxer_app/src/features/platform/state/DesktopLegacyImport.ts
index 474df99ca..19be62f14 100644
--- a/fluxer_app/src/features/platform/state/DesktopLegacyImport.ts
+++ b/fluxer_app/src/features/platform/state/DesktopLegacyImport.ts
@@ -47,7 +47,7 @@ import {
const logger = new Logger('DesktopLegacyImport');
-export const DESKTOP_LEGACY_IMPORT_MAX_FAILURES = 10;
+const DESKTOP_LEGACY_IMPORT_MAX_FAILURES = 10;
const LEGACY_CORPUS_STAMP = 0;
@@ -61,7 +61,7 @@ export const DesktopLegacyImportStatus = Object.freeze({
export type DesktopLegacyImportStatus = (typeof DesktopLegacyImportStatus)[keyof typeof DesktopLegacyImportStatus];
-export const DesktopLegacyImportRefusal = Object.freeze({
+const DesktopLegacyImportRefusal = Object.freeze({
STORE_UNAVAILABLE: 'store-unavailable',
STICKY_FALLBACK: 'sticky-fallback',
NO_LOCAL_STORAGE: 'no-local-storage',
@@ -69,7 +69,7 @@ export const DesktopLegacyImportRefusal = Object.freeze({
ACCOUNTS_NOT_AUTHORITATIVE: 'accounts-not-authoritative',
} as const);
-export type DesktopLegacyImportRefusal = (typeof DesktopLegacyImportRefusal)[keyof typeof DesktopLegacyImportRefusal];
+type DesktopLegacyImportRefusal = (typeof DesktopLegacyImportRefusal)[keyof typeof DesktopLegacyImportRefusal];
export interface DesktopLegacyImportAccountSource {
getAllAccounts(): Promise<StoredAccountList>;
@@ -447,7 +447,7 @@ async function storeNeedsReseed(
return !expectedKeys.has(context.activeAccountKey);
}
-export async function pruneDesktopLegacyAccounts(
+async function pruneDesktopLegacyAccounts(
request: DesktopLegacyImportRequest,
knownStorageKeys: ReadonlyArray<string>,
): Promise<ReadonlyArray<string>> {
diff --git a/fluxer_app/src/features/platform/state/LegacyAppStorageMigration.ts b/fluxer_app/src/features/platform/state/LegacyAppStorageMigration.ts
index a98969ed6..953d6223e 100644
--- a/fluxer_app/src/features/platform/state/LegacyAppStorageMigration.ts
+++ b/fluxer_app/src/features/platform/state/LegacyAppStorageMigration.ts
@@ -42,7 +42,8 @@ const logger = new Logger('LegacyAppStorageMigration');
const TEXT_ENCODER = new TextEncoder();
-export const LEGACY_APP_STORAGE_MIGRATION_VERSION = 1;
+const LEGACY_APP_STORAGE_MIGRATION_VERSION = 1;
+
export {LEGACY_APP_STORAGE_MIGRATION_MARKER_KEY};
export const LEGACY_APP_STORAGE_UNCLASSIFIED_KEYS_KEY = 'fluxer:migration:unclassified-legacy-keys';
@@ -57,7 +58,7 @@ export const LegacyAppStorageMigrationStatus = Object.freeze({
export type LegacyAppStorageMigrationStatus =
(typeof LegacyAppStorageMigrationStatus)[keyof typeof LegacyAppStorageMigrationStatus];
-export const LegacyAppStorageMigrationSkipReason = Object.freeze({
+const LegacyAppStorageMigrationSkipReason = Object.freeze({
MEMORY_BACKEND: 'memory-backend',
NO_LOCAL_STORAGE: 'no-local-storage',
NO_INSTANCE_KEY: 'no-instance-key',
@@ -65,7 +66,7 @@ export const LegacyAppStorageMigrationSkipReason = Object.freeze({
SCOPE_NOT_PENDING: 'scope-not-pending',
} as const);
-export type LegacyAppStorageMigrationSkipReason =
+type LegacyAppStorageMigrationSkipReason =
(typeof LegacyAppStorageMigrationSkipReason)[keyof typeof LegacyAppStorageMigrationSkipReason];
export interface LegacyContentCarry {
@@ -95,12 +96,12 @@ export interface LegacyAppStorageMigrationPlan {
readonly totalBytes: number;
}
-export interface LegacyAppStorageMigrationLimits {
+interface LegacyAppStorageMigrationLimits {
readonly maxTotalBytes: number;
readonly maxEntries: number;
}
-export interface LegacyAppStorageMigrationAccountSource {
+interface LegacyAppStorageMigrationAccountSource {
migrateAccountStorageKeys(context: AccountRekeyContext): Promise<AccountRekeyOutcome>;
}
diff --git a/fluxer_app/src/features/platform/state/LegacySessionReconciliation.ts b/fluxer_app/src/features/platform/state/LegacySessionReconciliation.ts
index 8105564af..2540ffb10 100644
--- a/fluxer_app/src/features/platform/state/LegacySessionReconciliation.ts
+++ b/fluxer_app/src/features/platform/state/LegacySessionReconciliation.ts
@@ -71,7 +71,7 @@ export interface LegacySessionReconciliationResult {
readonly reason: LegacySessionReconciliationSkipReason | null;
}
-export class LegacySessionAccountsNotAuthoritativeError extends Error {
+class LegacySessionAccountsNotAuthoritativeError extends Error {
public constructor(source: string) {
super(`The stored account list is not authoritative (source: ${source})`);
this.name = 'LegacySessionAccountsNotAuthoritativeError';
@@ -94,7 +94,7 @@ export function readLegacySessionCredentials(storage: Storage | null): LegacySes
return {userId, token};
}
-export function matchLegacySessionAccount(
+function matchLegacySessionAccount(
accounts: ReadonlyArray<KeyedStoredAccount>,
credentials: LegacySessionCredentials,
instance: RuntimeConfigSnapshot,
diff --git a/fluxer_app/src/features/platform/state/PrebootMirror.ts b/fluxer_app/src/features/platform/state/PrebootMirror.ts
index 507632dc6..e72051945 100644
--- a/fluxer_app/src/features/platform/state/PrebootMirror.ts
+++ b/fluxer_app/src/features/platform/state/PrebootMirror.ts
@@ -113,7 +113,7 @@ export function writeRawStorageItem(name: string, value: string | null): void {
}
}
-export function rawStorageLength(): number {
+function rawStorageLength(): number {
try {
return rawBinding.storage.length;
} catch (error) {
@@ -122,7 +122,7 @@ export function rawStorageLength(): number {
}
}
-export function rawStorageKeyAt(index: number): string | null {
+function rawStorageKeyAt(index: number): string | null {
try {
return rawBinding.storage.key(index);
} catch (error) {
diff --git a/fluxer_app/src/features/platform/state/PrebootNetworkHandoff.ts b/fluxer_app/src/features/platform/state/PrebootNetworkHandoff.ts
index c0e2b6628..d32ceed8a 100644
--- a/fluxer_app/src/features/platform/state/PrebootNetworkHandoff.ts
+++ b/fluxer_app/src/features/platform/state/PrebootNetworkHandoff.ts
@@ -4,7 +4,7 @@ import {isDesktopLocalAppDocument} from '@app/features/platform/DesktopLocalAppR
import {PREBOOT_NETWORK_HINT_STORAGE_KEY, writeRawStorageItem} from '@app/features/platform/state/PrebootMirror';
import {waitForAbortablePromise} from '@app/features/platform/utils/AbortablePromise';
-export const PREBOOT_NETWORK_HINT_VERSION = 1;
+const PREBOOT_NETWORK_HINT_VERSION = 1;
const PREBOOT_HANDOFF_MAX_AGE_MS = 60_000;
const MAX_HINT_FIELD_LENGTH = 2048;
diff --git a/fluxer_app/src/features/platform/state/auth_session/AuthSessionRestorer.ts b/fluxer_app/src/features/platform/state/auth_session/AuthSessionRestorer.ts
index b5878bba8..d63ae1137 100644
--- a/fluxer_app/src/features/platform/state/auth_session/AuthSessionRestorer.ts
+++ b/fluxer_app/src/features/platform/state/auth_session/AuthSessionRestorer.ts
@@ -21,7 +21,7 @@ import type {
StoredSessionMirror,
} from '@app/features/platform/state/auth_session/SessionCredentialMirror';
-export type AuthSessionSignedOutReason = 'no-session-pointer' | ActiveStoredAccountUnresolvedReason;
+type AuthSessionSignedOutReason = 'no-session-pointer' | ActiveStoredAccountUnresolvedReason;
export type AuthSessionInitialization =
| {
diff --git a/fluxer_app/src/features/platform/state/auth_session/AuthSessionStoredAccountResolver.ts b/fluxer_app/src/features/platform/state/auth_session/AuthSessionStoredAccountResolver.ts
index 34b5a6977..0943184d2 100644
--- a/fluxer_app/src/features/platform/state/auth_session/AuthSessionStoredAccountResolver.ts
+++ b/fluxer_app/src/features/platform/state/auth_session/AuthSessionStoredAccountResolver.ts
@@ -38,7 +38,7 @@ export interface ResolvedActiveStoredAccountRestoration {
readonly usedMirroredCredential: boolean;
}
-export interface SignedOutActiveStoredAccountRestoration {
+interface SignedOutActiveStoredAccountRestoration {
readonly kind: 'signed-out';
readonly inventory: StoredAccountInventory;
readonly reason: 'no-session-pointer';
@@ -53,7 +53,7 @@ export type ActiveStoredAccountUnresolvedReason =
| 'runtime-identity-unavailable'
| 'unavailable-account';
-export interface UnresolvedActiveStoredAccountRestoration {
+interface UnresolvedActiveStoredAccountRestoration {
readonly kind: 'unresolved';
readonly inventory: StoredAccountInventory;
readonly reason: ActiveStoredAccountUnresolvedReason;
@@ -74,7 +74,7 @@ export class StoredAccountNotFoundError extends Error {
}
}
-export class StoredAccountSelectionAmbiguityError extends Error {
+class StoredAccountSelectionAmbiguityError extends Error {
readonly accountKey: string;
constructor(accountKey: string) {
@@ -84,7 +84,7 @@ export class StoredAccountSelectionAmbiguityError extends Error {
}
}
-export class StoredAccountRuntimeIdentityUnavailableError extends Error {
+class StoredAccountRuntimeIdentityUnavailableError extends Error {
readonly accountKey: string;
constructor(accountKey: string) {
@@ -94,7 +94,7 @@ export class StoredAccountRuntimeIdentityUnavailableError extends Error {
}
}
-export class StoredAccountRuntimeIdentityMismatchError extends Error {
+class StoredAccountRuntimeIdentityMismatchError extends Error {
readonly accountKey: string;
readonly expectedInstanceKey: string;
readonly resolvedInstanceKey: string;
@@ -108,7 +108,7 @@ export class StoredAccountRuntimeIdentityMismatchError extends Error {
}
}
-export class StoredAccountStorageIdentityMismatchError extends Error {
+class StoredAccountStorageIdentityMismatchError extends Error {
readonly accountKey: string;
readonly derivedAccountKey: string | null;
@@ -120,7 +120,7 @@ export class StoredAccountStorageIdentityMismatchError extends Error {
}
}
-export class StoredAccountReplacementInvariantError extends Error {
+class StoredAccountReplacementInvariantError extends Error {
readonly accountKey: string;
constructor(accountKey: string, message: string) {
@@ -380,21 +380,16 @@ export class AuthSessionStoredAccountResolver {
entry: ReplaceableStoredAccountEntry,
mirroredCredential: StoredSessionCredential | null,
): Promise<ActiveStoredAccountRestoration> {
+ const storedToken = entry.kind === 'ready' ? entry.record.token : entry.data.token;
const selectedToken =
- inventory.source === 'idb' && mirroredCredential !== null
- ? mirroredCredential.token
- : entry.kind === 'ready'
- ? entry.record.token
- : entry.data.token;
+ inventory.source === 'idb' && mirroredCredential !== null ? mirroredCredential.token : storedToken;
if (selectedToken === null) {
return {kind: 'unresolved', inventory, reason: 'missing-credential'};
}
if (entry.kind === 'runtime-recovery') {
- const storedToken = entry.data.token;
const replacement = await this.recoverRuntime(entry, selectedToken);
return await this.resolvedAfterReplacement(replacement, storedToken !== selectedToken);
}
- const storedToken = entry.record.token;
if (inventory.source !== 'idb' || storedToken === selectedToken) {
return {
kind: 'resolved',
diff --git a/fluxer_app/src/features/platform/state/auth_session/AuthSessionTransitionGate.ts b/fluxer_app/src/features/platform/state/auth_session/AuthSessionTransitionGate.ts
index 2ff214698..865ac3fea 100644
--- a/fluxer_app/src/features/platform/state/auth_session/AuthSessionTransitionGate.ts
+++ b/fluxer_app/src/features/platform/state/auth_session/AuthSessionTransitionGate.ts
@@ -16,14 +16,14 @@ export interface AuthSessionTransitionDependencies {
): Promise<Result>;
}
-export class AuthSessionTransitionCapacityError extends Error {
+class AuthSessionTransitionCapacityError extends Error {
constructor() {
super('Auth session transitions already have one active operation and one queued operation');
this.name = 'AuthSessionTransitionCapacityError';
}
}
-export class AuthSessionTransitionInvariantError extends Error {
+class AuthSessionTransitionInvariantError extends Error {
constructor(message: string) {
super(message);
this.name = 'AuthSessionTransitionInvariantError';
diff --git a/fluxer_app/src/features/platform/state/auth_session/SessionCredentialMirror.ts b/fluxer_app/src/features/platform/state/auth_session/SessionCredentialMirror.ts
index 95a991717..6f9d5c886 100644
--- a/fluxer_app/src/features/platform/state/auth_session/SessionCredentialMirror.ts
+++ b/fluxer_app/src/features/platform/state/auth_session/SessionCredentialMirror.ts
@@ -40,7 +40,7 @@ export interface SessionCredentialMirror {
persist(mirror: StoredSessionMirror): Promise<void>;
}
-export class SessionCredentialMirrorReadError extends Error {
+class SessionCredentialMirrorReadError extends Error {
constructor(cause: unknown) {
super('The session credential mirror is unreadable', {cause});
this.name = 'SessionCredentialMirrorReadError';
diff --git a/fluxer_app/src/features/platform/transport/InstanceHTTP.ts b/fluxer_app/src/features/platform/transport/InstanceHTTP.ts
index 3281c96e7..09da124e6 100644
--- a/fluxer_app/src/features/platform/transport/InstanceHTTP.ts
+++ b/fluxer_app/src/features/platform/transport/InstanceHTTP.ts
@@ -36,7 +36,7 @@ export interface InstanceHTTPRequest {
readonly signal?: AbortSignal;
}
-export class InvalidInstanceHTTPTargetError extends Error {
+class InvalidInstanceHTTPTargetError extends Error {
constructor(message: string) {
super(message);
this.name = 'InvalidInstanceHTTPTargetError';
@@ -81,7 +81,7 @@ export function currentInstanceTarget(): InstanceHTTPTarget {
return instanceTargetFromSnapshot(RuntimeConfig.getSnapshot());
}
-export function composeInstanceRequestPath(target: InstanceHTTPTarget, path: string): string {
+function composeInstanceRequestPath(target: InstanceHTTPTarget, path: string): string {
validateInstanceTarget(target);
if (http.matchesConfiguredRouting(target.apiEndpoint, target.apiVersion)) {
return path;
diff --git a/fluxer_app/src/features/platform/utils/LazyModuleLoader.ts b/fluxer_app/src/features/platform/utils/LazyModuleLoader.ts
index e30da68cf..aae3bbf95 100644
--- a/fluxer_app/src/features/platform/utils/LazyModuleLoader.ts
+++ b/fluxer_app/src/features/platform/utils/LazyModuleLoader.ts
@@ -2,9 +2,9 @@
import {getProtectedSessionStorage} from '@app/features/platform/state/ProtectedWebStorage';
-export const DEFAULT_LAZY_MODULE_LOAD_ATTEMPTS = 3;
-export const DEFAULT_LAZY_MODULE_RETRY_DELAY_MS = 250;
-export const MAX_LAZY_MODULE_RETRY_DELAY_MS = 2000;
+const DEFAULT_LAZY_MODULE_LOAD_ATTEMPTS = 3;
+const DEFAULT_LAZY_MODULE_RETRY_DELAY_MS = 250;
+const MAX_LAZY_MODULE_RETRY_DELAY_MS = 2000;
const RECOVERY_RELOAD_STORAGE_KEY = 'fluxer.lazyModuleRecoveryReload';