Skip to content

Commit 4782998

Browse files
geroplroboquat
authored andcommitted
[dashboard] UserDetail: Filter out deleted subscription
1 parent eefe632 commit 4782998

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

components/dashboard/src/admin/UserDetail.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,9 @@ export default function UserDetail(p: { user: User }) {
190190
>
191191
{accountStatement?.subscriptions
192192
? accountStatement.subscriptions
193-
.filter((s) => Subscription.isActive(s, new Date().toISOString()))
193+
.filter(
194+
(s) => !s.deleted && Subscription.isActive(s, new Date().toISOString()),
195+
)
194196
.map((s) => Plans.getById(s.planId)?.name)
195197
.join(", ")
196198
: "---"}

0 commit comments

Comments
 (0)