feat: desk IA

This commit is contained in:
OpenSquared
2026-06-28 17:14:40 +02:00
parent bab09a1b09
commit c286c7c000
2 changed files with 4 additions and 3 deletions

View File

@@ -5135,7 +5135,8 @@ def get_all_ai_desks() -> List[Dict[str, Any]]:
d = dict(r)
for f in ("instruments", "config"):
try:
d[f] = json.loads(d.get(f) or "[]" if f == "instruments" else "{}")
fallback = "[]" if f == "instruments" else "{}"
d[f] = json.loads(d.get(f) or fallback)
except Exception:
d[f] = [] if f == "instruments" else {}
result.append(d)