[Staleness] Fix removed object error and clean up (#6241)

* fixing error from plots when removing swg and making methods and props private for swg staleness provider

* removing unsubscribes from destroy hooks if the item has been removed already and reverting an unneccesary change

* checking for undefined staleness response

* removed un-neccesary code
This commit is contained in:
Jamie V
2023-02-01 14:06:54 -08:00
committed by GitHub
parent c1c1d87953
commit c1e8c7915c
6 changed files with 72 additions and 55 deletions

View File

@ -293,6 +293,7 @@ define([
this.stalenessSubscription[keyString].unsubscribe();
this.stalenessSubscription[keyString].stalenessUtils.destroy();
this.handleStaleness(keyString, { isStale: false }, SKIP_CHECK);
delete this.stalenessSubscription[keyString];
}
clearData() {