Skip to content

Commit

Permalink
Fix error
Browse files Browse the repository at this point in the history
  • Loading branch information
micafer committed Dec 13, 2024
1 parent 91970cb commit 3316391
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions app/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -986,5 +986,11 @@ def merge_templates(template, new_template):

def get_cache_creds(session, cred, userid, enabled=None):
if "creds" not in session:
session["creds"] = cred.get_creds(userid, enabled)
return session["creds"]
session["creds"] = cred.get_creds(userid)

res = []
for cred in session["creds"]:
if enabled is None or enabled == cred['enabled']:
res.append(cred)

return res

0 comments on commit 3316391

Please sign in to comment.