From 59bb4e6d5e93e64786337fa8cb24dfa7a186ce30 Mon Sep 17 00:00:00 2001 From: ldm0 Date: Tue, 6 Oct 2026 08:47:36 +0800 Subject: [PATCH] fix(file-api): retire owner URLs through the shared target store MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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. --- moli-file-api/src/blob_store.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/moli-file-api/src/blob_store.rs b/moli-file-api/src/blob_store.rs index aa9caed482..61b582bc86 100644 --- a/moli-file-api/src/blob_store.rs +++ b/moli-file-api/src/blob_store.rs @@ -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) {