From be208cc5eb0d0f2b6594211f7730c8c10f5dfc25 Mon Sep 17 00:00:00 2001 From: Zach Whelchel Date: Thu, 11 Jan 2024 18:07:24 -0500 Subject: [PATCH] Added default institution name. --- packages/loot-core/src/server/main.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/packages/loot-core/src/server/main.ts b/packages/loot-core/src/server/main.ts index eaf964bd5a6..1a229baba38 100644 --- a/packages/loot-core/src/server/main.ts +++ b/packages/loot-core/src/server/main.ts @@ -710,8 +710,14 @@ handlers['simplefin-accounts-link'] = async function ({ }) { let id; + let institution = externalAccount.institution; + + if (institution == null) { + institution = {name: "Unknown"}; + } + const bank = await link.findOrCreateBank( - externalAccount.institution, + institution, externalAccount.orgDomain, );