Index: content/child/resource_dispatcher.cc |
diff --git a/content/child/resource_dispatcher.cc b/content/child/resource_dispatcher.cc |
index 922681bbbf841dab5c70e8745ddfd8da37885813..5604934bba85a99172d6eaca01acc8513203bf88 100644 |
--- a/content/child/resource_dispatcher.cc |
+++ b/content/child/resource_dispatcher.cc |
@@ -358,6 +358,13 @@ void ResourceDispatcher::OnReceivedResponse( |
request_info->peer = new_peer; |
} |
+ // Updates the response_url if the response was feched via ServiceWorker, and |
+ // it was not generated inside the SherviceWorker. |
+ if (response_head.was_fetched_via_service_worker && |
+ !response_head.original_url_via_service_worker.is_empty()) { |
+ request_info->response_url = response_head.original_url_via_service_worker; |
+ } |
+ |
ResourceResponseInfo renderer_response_info; |
ToResourceResponseInfo(*request_info, response_head, &renderer_response_info); |
request_info->site_isolation_metadata = |