Currently, when adding content script to only top frame, dispatchGlobalObjectAvailable won't be called for its subframes. If user later calls runJavaScriptInFrameInScriptWorld directly in the subframe using the same world as the content script added to top frame, dispatchGlobalObjectAvailable won't be called for the subframe either. In the end, objects that is registered in dispatchGlobalObjectAvailable callback won't be available for JavaScript that is executed by runJavaScriptInFrameInScriptWorld in subframe.
Pull request: https://github.com/WebKit/WebKit/pull/3059
Committed 253337@main (4b458ff27f44): <https://commits.webkit.org/253337@main> Reviewed commits have been landed. Closing PR #3059 and removing active labels.
<rdar://problem/98514341>
<rdar://problem/73500002>