A music player that connects to your cloud/distributed storage.
5
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: unregister process when ready

+9 -2
+9 -2
src/components/orchestrator/process-tracks/element.js
··· 109 109 // Process whenever tracks are initially loaded; 110 110 // unless already done so (possibly through another instance of this element) 111 111 if (this.hasAttribute("process-when-ready")) { 112 + let unregistered = false; 113 + 112 114 const unregister = this.effect(() => { 115 + if (unregistered) { 116 + unregister(); 117 + return; 118 + } 119 + 113 120 const col = output.tracks.collection(); 114 121 if (col.state !== "loaded") return; 115 122 116 123 if (this.#performedInitialProcess.value) { 117 - unregister(); 124 + unregistered = true; 118 125 return; 119 126 } 120 127 ··· 124 131 ?.DISABLE_AUTOMATIC_TRACKS_PROCESSING ?? false; 125 132 if (skip) return; 126 133 134 + unregistered = true; 127 135 untracked(() => this.process()); 128 - unregister(); 129 136 }); 130 137 } 131 138 }