From f4bc4923744b0daef30ccf62d9fa57af85264a6c Mon Sep 17 00:00:00 2001 From: Navin Karkera Date: Thu, 1 May 2025 11:52:07 +0530 Subject: [PATCH] fix: unwanted section of code causing security error https://github.com/openedx/edx-platform/pull/36477#discussion_r2069105832 --- common/templates/xblock_v2/xblock_iframe.html | 7 ------- 1 file changed, 7 deletions(-) diff --git a/common/templates/xblock_v2/xblock_iframe.html b/common/templates/xblock_v2/xblock_iframe.html index 39eb044b183e..ba4828df02ae 100644 --- a/common/templates/xblock_v2/xblock_iframe.html +++ b/common/templates/xblock_v2/xblock_iframe.html @@ -455,9 +455,6 @@ // it will report the height of its contents to the parent window when the // document loads, window resizes, or DOM mutates. if (window !== window.parent) { - var lastHeight = window.parent[0].offsetHeight; - var lastWidth = window.parent[0].offsetWidth; - function dispatchResizeMessage(event) { // Note: event is actually an Array of MutationRecord objects when fired from the MutationObserver var newHeight = rootNode.scrollHeight; @@ -472,10 +469,6 @@ } }, document.referrer ); - - lastHeight = newHeight; - lastWidth = newWidth; - // Within the authoring microfrontend the iframe resizes to match the // height of this document and it should never scroll. It does scroll // ocassionally when javascript is used to focus elements on the page