Skip to content

Commit

Permalink
BC-8398 - remove teams cache (#5335)
Browse files Browse the repository at this point in the history
only data that isnt subject to change should be
cached for langer than usual (1 sec by default)
  • Loading branch information
Metauriel authored and hoeppner-dataport committed Nov 18, 2024
1 parent 2d384b4 commit e0f82f9
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions apps/server/src/shared/repo/teams/teams.repo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@ export class TeamsRepo extends BaseRepo<TeamEntity> {
return TeamEntity;
}

cacheExpiration = 60000;

async findById(id: EntityId, populate = false): Promise<TeamEntity> {
const team = await this._em.findOneOrFail(TeamEntity, { id }, { cache: this.cacheExpiration });
const team = await this._em.findOneOrFail(TeamEntity, { id });

if (populate) {
await Promise.all<void>(
Expand Down

0 comments on commit e0f82f9

Please sign in to comment.