mirror of
https://github.com/nasa/openmct.git
synced 2025-05-27 12:44:20 +00:00
Destroy classes and unsubscribe when condition set view is destroyed
This commit is contained in:
parent
0beda1d053
commit
d98b54bea7
@ -40,6 +40,12 @@ export default {
|
|||||||
condition: this.condition
|
condition: this.condition
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
destroyed() {
|
||||||
|
this.conditionClass.off('conditionResultUpdated', this.handleConditionResult.bind(this));
|
||||||
|
if (this.conditionClass && typeof this.conditionClass.destroy === 'function') {
|
||||||
|
this.conditionClass.destroy();
|
||||||
|
}
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.openmct.objects.get(this.conditionIdentifier).then((obj => {
|
this.openmct.objects.get(this.conditionIdentifier).then((obj => {
|
||||||
this.condition = obj;
|
this.condition = obj;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user