Browse Source

Recompute portfolio snapshot on portfolio change

pull/7403/head
Thomas Kaul 1 month ago
parent
commit
5f1715ace3
  1. 5
      apps/api/src/events/portfolio-changed.listener.ts

5
apps/api/src/events/portfolio-changed.listener.ts

@ -56,6 +56,11 @@ export class PortfolioChangedListener {
await this.redisCacheService.removePortfolioSnapshotsByUserId({ userId }); await this.redisCacheService.removePortfolioSnapshotsByUserId({ userId });
const user = await this.userService.user({ id: userId }); const user = await this.userService.user({ id: userId });
if (!user) {
return;
}
const userSettings = user.settings.settings; const userSettings = user.settings.settings;
const filters = this.apiService.buildFiltersFromUserSettings({ const filters = this.apiService.buildFiltersFromUserSettings({

Loading…
Cancel
Save