fix(file-api): retire owner URLs through the shared target store

Remove the departing owner’s URL bindings through the common store operation. Release Blob references for Blob targets while preserving MediaSource targets and resources retained by other owners.
This commit is contained in:
ldm0
2026-10-11 18:06:47 +08:00
parent 26c6c7ad5a
commit 59bb4e6d5e
+3 -1
View File
@@ -425,7 +425,9 @@ where
pub fn retire_owner_resources(&self, owner_id: OwnerId) {
let retired = self.take_object_urls_if(|state| state.owner_id == Some(owner_id));
for state in retired {
self.release_blob_object_url_ref(state.blob_id);
if let Some(blob_id) = state.target.blob_id() {
self.release_blob_object_url_ref(blob_id);
}
}
for blob in self.blobs.lock().by_id.values_mut() {
if blob.owner_id == Some(owner_id) {