Signal-iOS/SignalMessaging/Subscriptions/Stripe+StripeError.swift
Evan Hahn 8c7c35b887 Show better errors for credit/debit card failures
For example, if we get the `expired_card` error code back from Stripe,
we should show a specific error to the user.

This introduces some TODOs around error messages in a couple of spots.
We will revisit this when implementing PayPal monthly donations, as is
explained in the comments.

I tested this by using some of [Stripe's test numbers][0] (as well as
automated tests).

[0]: https://stripe.com/docs/testing#declined-payments
2022-12-13 15:45:24 -06:00

13 lines
206 B
Swift

//
// Copyright 2022 Signal Messenger, LLC
// SPDX-License-Identifier: AGPL-3.0-only
//
import Foundation
extension Stripe {
public struct StripeError: Error {
public let code: String
}
}