devicer.js 1.0.8 → 1.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "devicer.js",
3
- "version": "1.0.8",
3
+ "version": "1.0.9",
4
4
  "description": "Open-Source Digital Fingerprinting Middleware",
5
5
  "main": "src/main.js",
6
6
  "scripts": {
@@ -12,14 +12,18 @@ function compareArrays(arr1: any[], arr2: any[]): [number, number] {
12
12
  const subData = compareArrays(arr1[i], arr2[i]);
13
13
  fields += subData[0] - 1; // Subtract 1 for the index itself
14
14
  matches += subData[1];
15
- } else if (
15
+ }
16
+
17
+ else if (
16
18
  (typeof arr1[i] == "object" && arr1[i]) &&
17
19
  (typeof arr2[i] == "object" && arr2[i])
18
20
  ) {
19
21
  const subData = compareDatasets(arr1[i] as FPDataSet, arr2[i] as FPDataSet);
20
22
  fields += subData[0] - 1; // Subtract 1 for the index itself
21
23
  matches += subData[1];
22
- } else if (arr1[i] === arr2[i]) {
24
+ }
25
+
26
+ if (arr1[i] === arr2[i]) {
23
27
  matches++;
24
28
  }
25
29
  }