diff --git a/payment/manager.py b/payment/manager.py index cc193702..c5d83f5d 100644 --- a/payment/manager.py +++ b/payment/manager.py @@ -955,8 +955,11 @@ class PaymentManager( object ): def retrieve_or_make_accounts(self, user, host, token=None, include_deactivated=False): accounts = self.retrieve_accounts(user=user, host=host, include_deactivated=include_deactivated) - if len(accounts) > 0: + num_acct=len(accounts) + if num_acct == 1: return (accounts, False) + elif num_acct > 1: + return ((accounts[num_acct-1],), False) else: account = self.make_account(user=user, host=host, token=token) return ((account,), True)