Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion js/apbct-public-bundle.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/apbct-public-bundle_ext-protection.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/apbct-public-bundle_ext-protection_gathering.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/apbct-public-bundle_full-protection.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/apbct-public-bundle_full-protection_gathering.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/apbct-public-bundle_gathering.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/apbct-public-bundle_int-protection.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/apbct-public-bundle_int-protection_gathering.min.js

Large diffs are not rendered by default.

40 changes: 31 additions & 9 deletions js/prebuild/apbct-public-bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -3022,16 +3022,14 @@ class ApbctHandler {
let bloomPopup = document.querySelectorAll('div[class^="et_bloom_form_container"]').length > 0;
let pafeFormsFormElementor = document.querySelectorAll('div[class*="pafe-form"]').length > 0;
let otterForm = document.querySelectorAll('div [class*="otter-form"]').length > 0;
let smartQuizBuilder = document.querySelectorAll('form .sqbform, .fields_reorder_enabled').length > 0;
ctPublic.force_alt_cookies = smartFormsSign ||
jetpackCommentsForm ||
userRegistrationProForm ||
etPbDiviSubscriptionForm ||
fluentBookingApp ||
pafeFormsFormElementor ||
bloomPopup ||
otterForm ||
smartQuizBuilder;
otterForm;

setTimeout(function() {
if (!ctPublic.force_alt_cookies) {
Expand Down Expand Up @@ -3079,7 +3077,10 @@ class ApbctHandler {
if (isNeedToAddCleantalkDataCheckString) {
let addidionalCleantalkData = '';

if (!(+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token'))) {
if (!(
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
)) {
let noCookieData = getNoCookieData();
addidionalCleantalkData += '&' + 'data%5Bct_no_cookie_hidden_field%5D=' + noCookieData;
} else {
Expand All @@ -3093,7 +3094,10 @@ class ApbctHandler {
}

if (isNeedToAddCleantalkDataCheckFormData) {
if (!(+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token'))) {
if (!(
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
)) {
let noCookieData = getNoCookieData();
body.append('ct_no_cookie_hidden_field', noCookieData);
} else {
Expand Down Expand Up @@ -3148,7 +3152,10 @@ class ApbctHandler {
if (
args[1].body instanceof FormData || (typeof args[1].body.append === 'function')
) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
args[1].body.append(
'ct_bot_detector_event_token',
apbctLocalStorage.get('bot_detector_event_token'),
Expand Down Expand Up @@ -3435,6 +3442,12 @@ class ApbctHandler {
sourceSign.found = 'action=uael_register_user';
sourceSign.keepUnwrapped = true;
}
if (
settings.data.indexOf('action=SQBSubmitQuizAjax') !== -1
) {
sourceSign.found = 'action=SQBSubmitQuizAjax';
sourceSign.keepUnwrapped = true;
}
}
if ( typeof settings.url === 'string' ) {
if (settings.url.indexOf('wc-ajax=add_to_cart') !== -1) {
Expand All @@ -3446,7 +3459,10 @@ class ApbctHandler {
let eventToken = '';
let noCookieData = '';
let visibleFieldsString = '';
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
const token = new ApbctHandler().toolGetEventToken();
if (token) {
if (sourceSign.keepUnwrapped) {
Expand Down Expand Up @@ -3513,7 +3529,10 @@ class ApbctHandler {
options.data.requests[0].hasOwnProperty('path') &&
options.data.requests[0].path === '/wc/store/v1/cart/add-item'
) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
let token = localStorage.getItem('bot_detector_event_token');
options.data.requests[0].data.ct_bot_detector_event_token = token;
} else {
Expand All @@ -3525,7 +3544,10 @@ class ApbctHandler {

// checkout
if (options.path.includes('/wc/store/v1/checkout')) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
options.data.ct_bot_detector_event_token = localStorage.getItem('bot_detector_event_token');
} else {
if (ctPublic.data__cookies_type === 'none') {
Expand Down
40 changes: 31 additions & 9 deletions js/prebuild/apbct-public-bundle_ext-protection.js
Original file line number Diff line number Diff line change
Expand Up @@ -3022,16 +3022,14 @@ class ApbctHandler {
let bloomPopup = document.querySelectorAll('div[class^="et_bloom_form_container"]').length > 0;
let pafeFormsFormElementor = document.querySelectorAll('div[class*="pafe-form"]').length > 0;
let otterForm = document.querySelectorAll('div [class*="otter-form"]').length > 0;
let smartQuizBuilder = document.querySelectorAll('form .sqbform, .fields_reorder_enabled').length > 0;
ctPublic.force_alt_cookies = smartFormsSign ||
jetpackCommentsForm ||
userRegistrationProForm ||
etPbDiviSubscriptionForm ||
fluentBookingApp ||
pafeFormsFormElementor ||
bloomPopup ||
otterForm ||
smartQuizBuilder;
otterForm;

setTimeout(function() {
if (!ctPublic.force_alt_cookies) {
Expand Down Expand Up @@ -3079,7 +3077,10 @@ class ApbctHandler {
if (isNeedToAddCleantalkDataCheckString) {
let addidionalCleantalkData = '';

if (!(+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token'))) {
if (!(
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
)) {
let noCookieData = getNoCookieData();
addidionalCleantalkData += '&' + 'data%5Bct_no_cookie_hidden_field%5D=' + noCookieData;
} else {
Expand All @@ -3093,7 +3094,10 @@ class ApbctHandler {
}

if (isNeedToAddCleantalkDataCheckFormData) {
if (!(+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token'))) {
if (!(
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
)) {
let noCookieData = getNoCookieData();
body.append('ct_no_cookie_hidden_field', noCookieData);
} else {
Expand Down Expand Up @@ -3148,7 +3152,10 @@ class ApbctHandler {
if (
args[1].body instanceof FormData || (typeof args[1].body.append === 'function')
) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
args[1].body.append(
'ct_bot_detector_event_token',
apbctLocalStorage.get('bot_detector_event_token'),
Expand Down Expand Up @@ -3435,6 +3442,12 @@ class ApbctHandler {
sourceSign.found = 'action=uael_register_user';
sourceSign.keepUnwrapped = true;
}
if (
settings.data.indexOf('action=SQBSubmitQuizAjax') !== -1
) {
sourceSign.found = 'action=SQBSubmitQuizAjax';
sourceSign.keepUnwrapped = true;
}
}
if ( typeof settings.url === 'string' ) {
if (settings.url.indexOf('wc-ajax=add_to_cart') !== -1) {
Expand All @@ -3446,7 +3459,10 @@ class ApbctHandler {
let eventToken = '';
let noCookieData = '';
let visibleFieldsString = '';
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
const token = new ApbctHandler().toolGetEventToken();
if (token) {
if (sourceSign.keepUnwrapped) {
Expand Down Expand Up @@ -3513,7 +3529,10 @@ class ApbctHandler {
options.data.requests[0].hasOwnProperty('path') &&
options.data.requests[0].path === '/wc/store/v1/cart/add-item'
) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
let token = localStorage.getItem('bot_detector_event_token');
options.data.requests[0].data.ct_bot_detector_event_token = token;
} else {
Expand All @@ -3525,7 +3544,10 @@ class ApbctHandler {

// checkout
if (options.path.includes('/wc/store/v1/checkout')) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
options.data.ct_bot_detector_event_token = localStorage.getItem('bot_detector_event_token');
} else {
if (ctPublic.data__cookies_type === 'none') {
Expand Down
40 changes: 31 additions & 9 deletions js/prebuild/apbct-public-bundle_ext-protection_gathering.js
Original file line number Diff line number Diff line change
Expand Up @@ -3022,16 +3022,14 @@ class ApbctHandler {
let bloomPopup = document.querySelectorAll('div[class^="et_bloom_form_container"]').length > 0;
let pafeFormsFormElementor = document.querySelectorAll('div[class*="pafe-form"]').length > 0;
let otterForm = document.querySelectorAll('div [class*="otter-form"]').length > 0;
let smartQuizBuilder = document.querySelectorAll('form .sqbform, .fields_reorder_enabled').length > 0;
ctPublic.force_alt_cookies = smartFormsSign ||
jetpackCommentsForm ||
userRegistrationProForm ||
etPbDiviSubscriptionForm ||
fluentBookingApp ||
pafeFormsFormElementor ||
bloomPopup ||
otterForm ||
smartQuizBuilder;
otterForm;

setTimeout(function() {
if (!ctPublic.force_alt_cookies) {
Expand Down Expand Up @@ -3079,7 +3077,10 @@ class ApbctHandler {
if (isNeedToAddCleantalkDataCheckString) {
let addidionalCleantalkData = '';

if (!(+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token'))) {
if (!(
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
)) {
let noCookieData = getNoCookieData();
addidionalCleantalkData += '&' + 'data%5Bct_no_cookie_hidden_field%5D=' + noCookieData;
} else {
Expand All @@ -3093,7 +3094,10 @@ class ApbctHandler {
}

if (isNeedToAddCleantalkDataCheckFormData) {
if (!(+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token'))) {
if (!(
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
)) {
let noCookieData = getNoCookieData();
body.append('ct_no_cookie_hidden_field', noCookieData);
} else {
Expand Down Expand Up @@ -3148,7 +3152,10 @@ class ApbctHandler {
if (
args[1].body instanceof FormData || (typeof args[1].body.append === 'function')
) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
args[1].body.append(
'ct_bot_detector_event_token',
apbctLocalStorage.get('bot_detector_event_token'),
Expand Down Expand Up @@ -3435,6 +3442,12 @@ class ApbctHandler {
sourceSign.found = 'action=uael_register_user';
sourceSign.keepUnwrapped = true;
}
if (
settings.data.indexOf('action=SQBSubmitQuizAjax') !== -1
) {
sourceSign.found = 'action=SQBSubmitQuizAjax';
sourceSign.keepUnwrapped = true;
}
}
if ( typeof settings.url === 'string' ) {
if (settings.url.indexOf('wc-ajax=add_to_cart') !== -1) {
Expand All @@ -3446,7 +3459,10 @@ class ApbctHandler {
let eventToken = '';
let noCookieData = '';
let visibleFieldsString = '';
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
const token = new ApbctHandler().toolGetEventToken();
if (token) {
if (sourceSign.keepUnwrapped) {
Expand Down Expand Up @@ -3513,7 +3529,10 @@ class ApbctHandler {
options.data.requests[0].hasOwnProperty('path') &&
options.data.requests[0].path === '/wc/store/v1/cart/add-item'
) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
let token = localStorage.getItem('bot_detector_event_token');
options.data.requests[0].data.ct_bot_detector_event_token = token;
} else {
Expand All @@ -3525,7 +3544,10 @@ class ApbctHandler {

// checkout
if (options.path.includes('/wc/store/v1/checkout')) {
if (+ctPublic.settings__data__bot_detector_enabled && apbctLocalStorage.get('bot_detector_event_token')) {
if (
+ctPublic.settings__data__bot_detector_enabled &&
apbctLocalStorage.get('bot_detector_event_token')
) {
options.data.ct_bot_detector_event_token = localStorage.getItem('bot_detector_event_token');
} else {
if (ctPublic.data__cookies_type === 'none') {
Expand Down
Loading