Skip to content

Commit

Permalink
🐛 set cache after insert
Browse files Browse the repository at this point in the history
  • Loading branch information
elmarti committed Oct 16, 2021
1 parent a7635c7 commit 1e4b42d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/modules/persistence/fs/fs-persistence.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import PQueue from 'p-queue';
import { IFS } from '../../../interfaces/fs.interface';
import { ICamaConfig } from '../../../interfaces/cama-config.interface';
import * as path from 'path';
import sift from 'sift';
import { ILogger } from '../../../interfaces/logger.interface';
import { LogLevel } from '../../../interfaces/logger-level.enum';

Expand Down Expand Up @@ -51,7 +50,7 @@ export default class FSPersistence implements IPersistenceAdapter {
const data = [...(await this.getData()), ...rows];
await this.fs.writeData(outputPath, this.collectionName, data);
await this.fs.commit(outputPath, this.collectionName);
this.cache = null;
this.cache = data;
});
}

Expand Down

0 comments on commit 1e4b42d

Please sign in to comment.