LibWeb/HTML: Return an opaque origin for data URLs for Workers

This commit is contained in:
Shannon Booth 2025-05-24 21:10:19 +12:00 committed by Tim Flynn
parent 9aabe88795
commit 8ccb89877a
Notes: github-actions[bot] 2025-05-24 13:52:38 +00:00

View file

@ -62,7 +62,9 @@ URL::URL WorkerEnvironmentSettingsObject::api_base_url() const
URL::Origin WorkerEnvironmentSettingsObject::origin() const
{
// FIXME: Return a unique opaque origin if worker global scope's url's scheme is "data", and inherited origin otherwise.
// Return a unique opaque origin if worker global scope's url's scheme is "data", and inherited origin otherwise.
if (m_global_scope->url().scheme() == "data")
return URL::Origin {};
return m_origin;
}