From 6f844bdb8fc2b69a9a0e95d679dc641564813585 Mon Sep 17 00:00:00 2001 From: dishenwang2023 Date: Sun, 26 May 2024 11:14:51 -0400 Subject: [PATCH] Updated enterprise env var example --- services/enterprise/.env.example | 3 ++- services/enterprise/utils/auth.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/services/enterprise/.env.example b/services/enterprise/.env.example index 447b0988..2564c286 100644 --- a/services/enterprise/.env.example +++ b/services/enterprise/.env.example @@ -34,7 +34,8 @@ POSTHOG_HOST= SSH_PRIVATE_KEY_PASSWORD= SSH_PATH_TO_CREDENTIAL_FILE= -# Optional stripe env vars if organizations are not on ENTERPRISE plan +# Optional stripe env vars if organizations are only on ENTERPRISE plan (organization.invoice_details.plan = "ENTERPRISE") +# Otherwise you would need to create a new stripe account and fillout the env vars below STRIPE_API_KEY= STRIPE_WEBHOOK_SECRET= SQL_GENERATION_PRICE_ID= diff --git a/services/enterprise/utils/auth.py b/services/enterprise/utils/auth.py index 0fbe6b9c..67a22a1f 100644 --- a/services/enterprise/utils/auth.py +++ b/services/enterprise/utils/auth.py @@ -80,7 +80,7 @@ def _decode_payload(self): class Authorize: def user(self, payload: dict) -> User: - sub = payload['sub'] + sub = payload["sub"] user = user_service.get_user_by_sub(sub) if not user: raise UnauthorizedUserError(email=sub)