Created
January 23, 2025 05:05
Console errors breaking Admin Stores Configuration on 2.4.7-p3 https://github.com/magento/magento2/issues/39541
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/vendor/paypal/module-braintree-core/view/adminhtml/web/js/system.js | |
+++ b/vendor/paypal/module-braintree-core/view/adminhtml/web/js/system.js | |
@@ -141,8 +141,8 @@ | |
messagingLogoPosition = $('.' + location + '-messaging-logo-position').val(), | |
messagingTextColor = $('.' + location + '-messaging-text-color').val(); | |
- locations.each(function (loc) { | |
- buttonTypes.each(function (type) { | |
+ locations.forEach(function (loc) { | |
+ buttonTypes.forEach(function (type) { | |
/* eslint-disable */ | |
$('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + loc + '-groups-button-location-' + loc + '-type-' + type + '-fields-button-location-' + loc + '-type-' + type + '-show-value"]').val(buttonShowStatus).click(); | |
$('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + loc + '-groups-button-location-' + loc + '-type-' + type + '-fields-button-location-' + loc + '-type-' + type + '-label-value"]').val(buttonLabel).click(); | |
@@ -165,8 +165,8 @@ | |
let locations = ['checkout', 'productpage', 'cart'], buttonTypes = ['paypal', 'paylater', 'credit'], | |
buttonShowStatus = 1, buttonLabel = 'paypal', buttonColor = 'gold', buttonShape = 'rect'; | |
- locations.each(function (loc) { | |
- buttonTypes.each(function (type) { | |
+ locations.forEach(function (loc) { | |
+ buttonTypes.forEach(function (type) { | |
/* eslint-disable */ | |
$('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + loc + '-groups-button-location-' + loc + '-type-' + type + '-fields-button-location-' + loc + '-type-' + type + '-show-value"]').val(buttonShowStatus).click(); | |
$('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + loc + '-groups-button-location-' + loc + '-type-' + type + '-fields-button-location-' + loc + '-type-' + type + '-label-value"]').val(buttonLabel).click(); | |
@@ -188,8 +188,8 @@ | |
window.applyButton = function () { | |
let locations = ['checkout', 'productpage', 'cart'], buttonTypes = ['paypal', 'paylater', 'credit']; | |
- locations.each(function (loc) { | |
- buttonTypes.each(function (type) { | |
+ locations.forEach(function (loc) { | |
+ buttonTypes.forEach(function (type) { | |
/* eslint-disable */ | |
$('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + loc + '-groups-button-location-' + loc + '-type-' + type + '-fields-button-location-' + loc + '-type-' + type + '-show-value"]').click(); | |
$('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + loc + '-groups-button-location-' + loc + '-type-' + type + '-fields-button-location-' + loc + '-type-' + type + '-label-value"]').click(); | |
@@ -219,10 +219,10 @@ | |
merchantCountryIndex = mainLocation.attr('id').split('_')[1]; | |
// eslint-disable-next-line | |
mainType = $('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + mainLocation.val() + '-fields-paypal-location-' + mainLocation.val() + '-button-type-value"]'); | |
- locations.each(function (loc) { | |
+ locations.forEach(function (loc) { | |
// eslint-disable-next-line | |
$('#row_payment_' + merchantCountryIndex + '_braintree_section_braintree_braintree_paypal_styling_button_' + loc).hide(); | |
- buttonTypes.each(function (type) { | |
+ buttonTypes.forEach(function (type) { | |
// eslint-disable-next-line | |
$('#row_payment_' + merchantCountryIndex + '_braintree_section_braintree_braintree_paypal_styling_button_' + loc + '_button_location_' + loc + '_type_' + type).hide(); | |
}); | |
@@ -236,7 +236,7 @@ | |
let locations = ['checkout', 'productpage', 'cart']; | |
window.hidePaypalSections(); | |
- locations.each(function (loc) { | |
+ locations.forEach(function (loc) { | |
// eslint-disable-next-line | |
$('[data-ui-id="select-groups-braintree-section-groups-braintree-groups-braintree-paypal-groups-styling-groups-button-' + loc + '-fields-paypal-location-' + loc + '-button-type-value"]').change(function () { | |
window.hidePaypalSections(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment