Compare commits

...
Sign in to create a new pull request.

1 commit

Author SHA1 Message Date
Aiden Cline
88ee3dcf55 fix again 2026-04-19 00:56:55 -05:00

View file

@ -762,7 +762,8 @@ export async function handler(
const billing = authInfo.billing
const billingUrl = `https://opencode.ai/workspace/${authInfo.workspaceID}/billing`
const membersUrl = `https://opencode.ai/workspace/${authInfo.workspaceID}/members`
if (!billing.paymentMethodID) throw new CreditsError(t("zen.api.error.noPaymentMethod", { billingUrl }))
if (billing.balance <= 0 && !billing.paymentMethodID)
throw new CreditsError(t("zen.api.error.noPaymentMethod", { billingUrl }))
if (billing.balance <= 0) throw new CreditsError(t("zen.api.error.insufficientBalance", { billingUrl }))
const now = new Date()