mirror of https://github.com/zulip/zulip.git
billing: Prevent setup_stripe from being run in production.
This commit is contained in:
parent
2e04cdbe5e
commit
b847a100a3
|
@ -1,5 +1,6 @@
|
|||
from zerver.lib.management import ZulipBaseCommand
|
||||
from corporate.models import Plan, Coupon, Customer
|
||||
from django.conf import settings
|
||||
from zerver.lib.management import ZulipBaseCommand
|
||||
from zproject.settings import get_secret
|
||||
|
||||
from typing import Any
|
||||
|
@ -11,6 +12,8 @@ class Command(ZulipBaseCommand):
|
|||
help = """Script to add the appropriate products and plans to Stripe."""
|
||||
|
||||
def handle(self, *args: Any, **options: Any) -> None:
|
||||
assert (settings.DEVELOPMENT or settings.TEST_SUITE)
|
||||
|
||||
Customer.objects.all().delete()
|
||||
Plan.objects.all().delete()
|
||||
Coupon.objects.all().delete()
|
||||
|
|
Loading…
Reference in New Issue