Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(219)

Unified Diff: third_party/WebKit/Source/core/loader/WorkerFetchContext.cpp

Issue 2918653004: Remove dup'ed code for RequestorOrigin and FirstPartyCookie (Closed)
Patch Set: . Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/loader/WorkerFetchContext.cpp
diff --git a/third_party/WebKit/Source/core/loader/WorkerFetchContext.cpp b/third_party/WebKit/Source/core/loader/WorkerFetchContext.cpp
index 76deee5af9b6c753fe60cd2aafd4b5debd845b3b..9738544126ee230b417f34fa765246a48425c2d6 100644
--- a/third_party/WebKit/Source/core/loader/WorkerFetchContext.cpp
+++ b/third_party/WebKit/Source/core/loader/WorkerFetchContext.cpp
@@ -262,10 +262,7 @@ void WorkerFetchContext::SetFirstPartyCookieAndRequestorOrigin(
ResourceRequest& out_request) {
if (out_request.FirstPartyForCookies().IsNull())
out_request.SetFirstPartyForCookies(FirstPartyForCookies());
- // TODO(mkwst): It would be cleaner to adjust blink::ResourceRequest to
- // initialize itself with a `nullptr` initiator so that this can be a simple
- // `isNull()` check. https://crbug.com/625969
- if (out_request.RequestorOrigin()->IsUnique())
+ if (!out_request.RequestorOrigin())
out_request.SetRequestorOrigin(GetSecurityOrigin());
}

Powered by Google App Engine
This is Rietveld 408576698