paisa-mcp 0.0.4 → 0.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -45242,13 +45242,17 @@ function settlementEnrichedData(description, type, source) {
45242
45242
  }
45243
45243
  // src/tools/transactions.ts
45244
45244
  async function runRescan(client) {
45245
- const learningRes = await client.get("/api/household-learning");
45246
- const bag = learningRes.data?.bag ?? {
45245
+ const EMPTY_BAG2 = {
45247
45246
  merchantAliases: [],
45248
45247
  personAliases: [],
45249
45248
  merchantRules: {},
45250
45249
  personRules: {}
45251
45250
  };
45251
+ let bag = EMPTY_BAG2;
45252
+ try {
45253
+ const learningRes = await client.get("/api/household-learning");
45254
+ bag = learningRes.data?.bag ?? EMPTY_BAG2;
45255
+ } catch {}
45252
45256
  const merchantsRes = await client.get("/api/merchants");
45253
45257
  const allMerchants = merchantsRes.data ?? [];
45254
45258
  const globalMerchants = allMerchants.filter((m2) => !m2.householdId && m2.cleanName).map((m2) => ({ id: m2.id, name: m2.cleanName }));
@@ -45551,5 +45555,5 @@ main().catch((err) => {
45551
45555
  process.exit(1);
45552
45556
  });
45553
45557
 
45554
- //# debugId=E58A7271779D454264756E2164756E21
45558
+ //# debugId=66937CD8E27A6C8364756E2164756E21
45555
45559
  //# sourceMappingURL=index.js.map