Skip to content

Commit 2f061e7

Browse files
committed
Removed Agent JavaScript v3
1 parent 980bf86 commit 2f061e7

File tree

5 files changed

+6
-38
lines changed

5 files changed

+6
-38
lines changed

CHANGELOG

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
Revision History for FraudLabs Pro Magento2
2+
2.3.3 2022-12-01
3+
Removed Agent JavaScript v3.
4+
25
2.3.2 2022-10-07
36
Supported item type classification.
47

Controller/Observer.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ public function processSendRequestToFraudLabsPro($order) {
196196
'device_fingerprint' => (isset($_COOKIE['flp_device'])) ? $_COOKIE['flp_device'] : '',
197197
'flp_checksum' => (isset($_COOKIE['flp_checksum'])) ? $_COOKIE['flp_checksum'] : '',
198198
'source' => 'magento',
199-
'source_version' => '2.3.2',
199+
'source_version' => '2.3.3',
200200
'items' => $item_sku,
201201
'coupon_code' => $order->getCouponCode() ? $order->getCouponCode() : '',
202202
'coupon_amount' => $order->getCouponCode() ? -($order->getDiscountAmount()) : '',

composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "hexasoft/module-fraudlabspro",
33
"description": "FraudLabs Pro Fraud Prevention plugin that screen the order transaction for online frauds. Fraud Prevention extension for Magento 2.",
4-
"version": "2.3.2",
4+
"version": "2.3.3",
55
"type": "magento2-module",
66
"require": {
77
"php": ">=5.5"

etc/module.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0"?>
22
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../lib/internal/Magento/Framework/Module/etc/module.xsd">
3-
<module name="Hexasoft_FraudLabsPro" setup_version="2.3.2">
3+
<module name="Hexasoft_FraudLabsPro" setup_version="2.3.3">
44
<sequence>
55
<module name="Magento_Sales"/>
66
</sequence>

view/frontend/web/fraudlabsproagent.js

-35
Original file line numberDiff line numberDiff line change
@@ -8,39 +8,4 @@
88
s.parentNode.insertBefore(e, s);
99
}
1010
(window.attachEvent) ? window.attachEvent('onload', s) : window.addEventListener('load', s, false);
11-
12-
function random(length) {
13-
var key = '';
14-
var patterns = '0123456789abcdefghijklmnopqrstuvwxyz';
15-
var patternsLength = patterns.length;
16-
for (var i=0; i<length; i++) {
17-
key += patterns.charAt(Math.floor(Math.random() * patternsLength));
18-
}
19-
return key;
20-
}
21-
22-
function setCookie(name, value) {
23-
document.cookie = name + "=" + (value || "") + "; path=/";
24-
}
25-
26-
function getCookie(name) {
27-
var cookies = document.cookie.split(";");
28-
for(var i=0; i<cookies.length; i++) {
29-
var cookiePair = cookies[i].split("=");
30-
if(name == cookiePair[0].trim()) {
31-
return decodeURIComponent(cookiePair[1]);
32-
}
33-
}
34-
return null;
35-
}
36-
37-
var sId = '';
38-
if (getCookie('ssId') !== null) {
39-
sId = getCookie('ssId');
40-
} else {
41-
sId = random(32);
42-
setCookie('ssId', sId);
43-
}
44-
45-
document.write('<script src="https://cdn.fraudlabspro.com/v3-agent.min.js"></script><script>var agent = new FraudLabsProAgent3("' + sId + '");window.onload = function() {agent.resolve();};</script>');
4611
})();

0 commit comments

Comments
 (0)