core, ios, android: name the resolved store purchase so the app finishes it without a sweep (#7659)

This commit is contained in:
spaced4ndy
2026-10-08 13:46:27 +00:00
committed by GitHub
parent c0c5ba8393
commit b4f1249436
18 changed files with 174 additions and 129 deletions
+4 -3
View File
@@ -3094,9 +3094,10 @@ func processReceivedMsg(_ res: ChatEvent) async {
BadgeModel.shared.setAlert(userId: user.userId, alert: badgeAlert)
}
}
case .storePurchaseResolved:
// whichever profile owns it: only the app can finish the store transaction
Task { await BadgeStore.shared.presentUnfinished() }
case let .storePurchaseCredited(user, invoiceId):
Task { await BadgeStore.shared.storePurchaseResolved(user, invoiceId) }
case let .storePurchaseRefused(user, invoiceId, refusal):
Task { await BadgeStore.shared.storePurchaseRefused(user, invoiceId, refusal) }
default:
logger.debug("unsupported event: \(res.responseType)")
}