mirror of
https://github.com/pretix/pretix.git
synced 2026-05-05 15:14:04 +00:00
Stripe: Fix a rare crash with malformed settings
This commit is contained in:
@@ -315,7 +315,7 @@ class StripeMethod(BasePaymentProvider):
|
||||
if self.settings.connect_client_id and not self.settings.secret_key:
|
||||
is_testmode = True
|
||||
else:
|
||||
is_testmode = '_test_' in self.settings.secret_key
|
||||
is_testmode = self.settings.secret_key and '_test_' in self.settings.secret_key
|
||||
if is_testmode:
|
||||
return mark_safe(
|
||||
_('The Stripe plugin is operating in test mode. You can use one of <a {args}>many test '
|
||||
|
||||
Reference in New Issue
Block a user