Skip to content

Commit

Permalink
fix: unlisten to annotation event beforeDestroy (#6690)
Browse files Browse the repository at this point in the history
* fix: unlisten to annotation event beforeDestroy

* refactor: `npm run lint:fix`

---------

Co-authored-by: Scott Bell <[email protected]>
  • Loading branch information
ozyx and scottbell authored May 24, 2023
1 parent 356c90c commit fea6838
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ export default {
await this.updateSelection(this.openmct.selection.get());
},
beforeDestroy() {
this.openmct.annotation.off('targetDomainObjectAnnotated', this.loadAnnotationForTargetObject);
this.openmct.selection.off('change', this.updateSelection);
const unobserveEntryFunctions = Object.values(this.unobserveEntries);
unobserveEntryFunctions.forEach((unobserveEntry) => {
Expand Down

0 comments on commit fea6838

Please sign in to comment.