Skip to content

Commit

Permalink
clear the store cache when the model changes
Browse files Browse the repository at this point in the history
  • Loading branch information
meirish committed Oct 31, 2018
1 parent a9f2470 commit 39b1900
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions ui/app/routes/vault/cluster/secrets/backend/list.js
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,11 @@ export default Route.extend({
let { backend } = this.paramsFor('vault.cluster.secrets.backend');
let backendModel = this.store.peekRecord('secret-engine', backend);
let has404 = this.get('has404');
// only clear store cache if this is a new model
if (secret !== controller.get('baseKey.id')) {
this.store.clearAllDatasets();
}

controller.set('hasModel', true);
controller.setProperties({
model,
Expand Down

0 comments on commit 39b1900

Please sign in to comment.