mirror of https://github.com/zulip/zulip.git
billing: Mention the exact type of stripe.Customers subscriptions attribute.
This commit is contained in:
parent
036ad03b3a
commit
c2023eaaa8
|
@ -1,5 +1,6 @@
|
||||||
import stripe.error as error
|
import stripe.error as error
|
||||||
import stripe.util as util
|
import stripe.util as util
|
||||||
|
from stripe.api_resources.list_object import SubscriptionListObject
|
||||||
|
|
||||||
from typing import Optional, Any, Dict, List
|
from typing import Optional, Any, Dict, List
|
||||||
|
|
||||||
|
@ -9,7 +10,7 @@ class Customer:
|
||||||
default_source: Card
|
default_source: Card
|
||||||
created: int
|
created: int
|
||||||
id: str
|
id: str
|
||||||
subscriptions: List[Subscription]
|
subscriptions: SubscriptionListObject
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def retrieve(customer_id: str, expand: Optional[List[str]]) -> Customer:
|
def retrieve(customer_id: str, expand: Optional[List[str]]) -> Customer:
|
||||||
|
|
|
@ -1,2 +1,8 @@
|
||||||
class ListObject:
|
from stripe import Subscription
|
||||||
|
from typing import Optional, Any, Dict, List, Iterator
|
||||||
|
|
||||||
|
class SubscriptionListObject:
|
||||||
|
data: List[Subscription]
|
||||||
|
|
||||||
|
def __iter__(self) -> Iterator[Subscription]:
|
||||||
...
|
...
|
||||||
|
|
|
@ -6,7 +6,6 @@ import ujson
|
||||||
from django.core import signing
|
from django.core import signing
|
||||||
|
|
||||||
import stripe
|
import stripe
|
||||||
from stripe.api_resources.list_object import ListObject
|
|
||||||
|
|
||||||
from zerver.lib.actions import do_deactivate_user, do_create_user, \
|
from zerver.lib.actions import do_deactivate_user, do_create_user, \
|
||||||
do_activate_user, do_reactivate_user, activity_change_requires_seat_update
|
do_activate_user, do_reactivate_user, activity_change_requires_seat_update
|
||||||
|
|
Loading…
Reference in New Issue