Skip to content

Commit

Permalink
Fixed account settings logic to handle no account case
Browse files Browse the repository at this point in the history
  • Loading branch information
matagus committed Mar 23, 2024
1 parent 5b5cfc7 commit ce1b286
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions jirahub/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ class Account(NamedTuple):

ACCOUNT_MAP = {}

for prefix in os.getenv("ACCOUNT_KEYS").split(","):
name, key, url, email, token = os.getenv(f"{prefix}_CONFIG").split(",")
ACCOUNT_MAP[key] = Account(key, name, url, email, token)
for prefix in env.list("ACCOUNT_KEYS", default="").split(","):
if prefix.strip():
name, key, url, email, token = os.getenv(f"{prefix}_CONFIG").split(",")
ACCOUNT_MAP[key] = Account(key, name, url, email, token)

0 comments on commit ce1b286

Please sign in to comment.