Skip to content

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

TypeScript fluxerfluxerapp

fix(app): handle premium state without billing documents (#3786)

Hampusf82aa5f5913c
diff --git a/fluxer_app/src/features/premium/state/PremiumState.ts b/fluxer_app/src/features/premium/state/PremiumState.ts
index 7844e97dc..6b5bb46cb 100644
--- a/fluxer_app/src/features/premium/state/PremiumState.ts
+++ b/fluxer_app/src/features/premium/state/PremiumState.ts
@@ -22,7 +22,7 @@ class PremiumState {
}
setState(userId: string, state: PremiumStateResponse): void {
- this.state = state;
+ this.state = {...state, billing: {...state.billing, documents: state.billing.documents ?? []}};
this.loadedForUserId = userId;
this.loading = false;
}