- StripeApiHandler methods can no longer be called directly.
- PaymentConfiguration now stores your public key and is depended upon for CustomerSession.
- Many Utils classes have been migrated to package-private access.
- Instantiation of a Stripe object can no longer throw an
AuthenticationException
.- Any time you were instantiating a Stripe object in a try/catch block will be simplified.
now becomesStripe stripe; try { stripe = new Stripe(mContext, MY_PUBLISHABLE_KEY); } catch (AuthenticationException authEx) { // This never happens because you check your key. }
Stripe stripe = new Stripe(mContext, MY_PUBLISHABLE_KEY);
Stripe#setDefaultPublishableKey(String key)
has similarly been changed, and no longer needs to be wrapped.- Both methods can still throw an
IllegalArgumentException
if an invalid key is used, but as a runtime exception, that does not need to be wrapped. AuthenticationException
will now only be thrown if you attempt to create aToken
orSource
with an invalid key.