From f95739b50b4748d84ecfc58164f6949ff06fcc9c Mon Sep 17 00:00:00 2001 From: Stephen Heaps Date: Tue, 14 Jan 2025 11:01:02 -0500 Subject: [PATCH] Remove Image.prototype.src getter/setter readonly protections. --- .../Scripts/Paged/TrackingProtectionStats.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ios/brave-ios/Sources/Brave/Frontend/UserContent/UserScripts/Scripts_Dynamic/Scripts/Paged/TrackingProtectionStats.js b/ios/brave-ios/Sources/Brave/Frontend/UserContent/UserScripts/Scripts_Dynamic/Scripts/Paged/TrackingProtectionStats.js index 06fa7af52cd7..a816b50fb066 100644 --- a/ios/brave-ios/Sources/Brave/Frontend/UserContent/UserScripts/Scripts_Dynamic/Scripts/Paged/TrackingProtectionStats.js +++ b/ios/brave-ios/Sources/Brave/Frontend/UserContent/UserScripts/Scripts_Dynamic/Scripts/Paged/TrackingProtectionStats.js @@ -166,11 +166,11 @@ window.__firefox__.execute(function($) { delete Image.prototype.src; Object.defineProperty(Image.prototype, "src", { - get: $(function() { + get: function() { return originalImageSrc.get.call(this); - }), + }, - set: $(function(value) { + set: function(value) { // Only attach the `error` event listener once for this // Image instance. if (!this[localErrorHandlerProp]) { @@ -184,7 +184,7 @@ window.__firefox__.execute(function($) { } originalImageSrc.set.call(this, value); - }), + }, enumerable: true, configurable: true });