From 323a387be66a4c18f08b40474d5b3d68dfac0b8d Mon Sep 17 00:00:00 2001 From: Aleksey Khoroshilov Date: Fri, 29 Mar 2024 18:58:28 +0700 Subject: [PATCH] Add comments to the added BlobURLStoreImpl logic. --- chromium_src/storage/browser/blob/blob_url_store_impl.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/chromium_src/storage/browser/blob/blob_url_store_impl.cc b/chromium_src/storage/browser/blob/blob_url_store_impl.cc index dbe8cd41ad0c..3c2b9cf6cec1 100644 --- a/chromium_src/storage/browser/blob/blob_url_store_impl.cc +++ b/chromium_src/storage/browser/blob/blob_url_store_impl.cc @@ -14,6 +14,8 @@ namespace storage { void BlobURLStoreImpl::Resolve(const GURL& url, ResolveCallback callback) { + // If a URL is not mapped to the current `storage_key_`, it's likely stored + // with a different StorageKey (partitioned) and should not be resolved. if (registry_ && !registry_->IsUrlMapped(url, storage_key_)) { std::move(callback).Run(mojo::NullRemote(), std::nullopt); return; @@ -26,6 +28,8 @@ void BlobURLStoreImpl::ResolveAsURLLoaderFactory( const GURL& url, mojo::PendingReceiver receiver, ResolveAsURLLoaderFactoryCallback callback) { + // If a URL is not mapped to the current `storage_key_`, it's likely stored + // with a different StorageKey (partitioned) and should not be resolved. if (registry_ && !registry_->IsUrlMapped(url, storage_key_)) { std::move(callback).Run(std::nullopt, std::nullopt); return; @@ -39,6 +43,8 @@ void BlobURLStoreImpl::ResolveForNavigation( const GURL& url, mojo::PendingReceiver token, ResolveForNavigationCallback callback) { + // If a URL is not mapped to the current `storage_key_`, it's likely stored + // with a different StorageKey (partitioned) and should not be resolved. if (registry_ && !registry_->IsUrlMapped(url, storage_key_)) { std::move(callback).Run(std::nullopt); return;