Skip to content

Commit

Permalink
Make Fastlane Component Compatible with Magento2.3.x
Browse files Browse the repository at this point in the history
  • Loading branch information
NickolasMalovanets committed Aug 1, 2024
1 parent 96d8480 commit 011f50d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions view/frontend/web/js/model/fastlane.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ define([
* @return {Promise<void>}
*/
buildBraintreeFastlaneInstance: async function (gatewayData) {
this.loadAxo(gatewayData);
this.rewriteAxoLoading(gatewayData); //todo: remove as soon as axo.js is compatible with require js.
await this.loadScript('bold_braintree_fastlane_hosted_fields', 'hostedFields');
const client = await this.loadScript('bold_braintree_fastlane_client');
const dataCollector = await this.loadScript('bold_braintree_fastlane_data_collector');
Expand Down Expand Up @@ -157,7 +157,7 @@ define([
* @return {Promise<void>}
*/
buildPPCPFastlaneInstance: async function (gatewayData) {
this.loadAxo(gatewayData);
this.rewriteAxoLoading(gatewayData); //todo: remove as soon as axo.js is compatible with require js.
await this.loadScript('bold_paypal_fastlane_hosted_fields', 'hostedFields');
await this.loadScript('bold_paypal_fastlane_client', 'client');
let debugMode = '';
Expand All @@ -181,7 +181,7 @@ define([
* @param {{client_token: string}} gatewayData
* @return {void}
*/
loadAxo: function (gatewayData) {
rewriteAxoLoading: function (gatewayData) {
this.saveEventListeners();
const originalAppendChild = Element.prototype.appendChild;
const self = this;
Expand Down

0 comments on commit 011f50d

Please sign in to comment.