MCPcopy Create free account
hub / github.com/OneNoteDev/WebClipper / tearDown

Method tearDown

src/scripts/communicator/communicator.ts:67–79  ·  view source on GitHub ↗

* Does any cleanup work needed

()

Source from the content-addressed store, hash-verified

65 * Does any cleanup work needed
66 */
67 public tearDown() {
68 // Unsubscribe to SVs
69 for (let svKey in this.trackedSmartValues) {
70 if (this.trackedSmartValues.hasOwnProperty(svKey)) {
71 if (this.svFunctions[svKey]) {
72 for (let i = 0; i < this.svFunctions[svKey].length; i++) {
73 this.trackedSmartValues[svKey].unsubscribe(this.svFunctions[svKey][i]);
74 }
75 }
76 }
77 }
78 this.messageHandler.tearDown();
79 }
80
81 /**
82 * Sets the error handler for when trying to communicate throws an error

Callers

nothing calls this directly

Calls 1

unsubscribeMethod · 0.80

Tested by

no test coverage detected