bn.js 5.1.1 → 5.1.2
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/CHANGELOG.md +5 -0
- package/lib/bn.js +7 -1
- package/package.json +19 -19
package/CHANGELOG.md
CHANGED
package/lib/bn.js
CHANGED
|
@@ -3073,7 +3073,13 @@
|
|
|
3073
3073
|
} else if (cmp > 0) {
|
|
3074
3074
|
r.isub(this.p);
|
|
3075
3075
|
} else {
|
|
3076
|
-
r.
|
|
3076
|
+
if (r.strip !== undefined) {
|
|
3077
|
+
// r is a BN v4 instance
|
|
3078
|
+
r.strip();
|
|
3079
|
+
} else {
|
|
3080
|
+
// r is a BN v5 instance
|
|
3081
|
+
r._strip();
|
|
3082
|
+
}
|
|
3077
3083
|
}
|
|
3078
3084
|
|
|
3079
3085
|
return r;
|
package/package.json
CHANGED
|
@@ -1,40 +1,40 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bn.js",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.2",
|
|
4
4
|
"description": "Big number implementation in pure javascript",
|
|
5
|
-
"main": "lib/bn.js",
|
|
6
|
-
"scripts": {
|
|
7
|
-
"lint": "standardx",
|
|
8
|
-
"unit": "mocha --reporter=spec test/*-test.js",
|
|
9
|
-
"test": "npm run lint && npm run unit"
|
|
10
|
-
},
|
|
11
|
-
"repository": {
|
|
12
|
-
"type": "git",
|
|
13
|
-
"url": "git@github.com:indutny/bn.js"
|
|
14
|
-
},
|
|
15
5
|
"keywords": [
|
|
16
6
|
"BN",
|
|
17
|
-
"BigNum",
|
|
18
7
|
"Big number",
|
|
8
|
+
"BigNum",
|
|
19
9
|
"Modulo",
|
|
20
10
|
"Montgomery"
|
|
21
11
|
],
|
|
22
|
-
"
|
|
23
|
-
"license": "MIT",
|
|
12
|
+
"homepage": "https://github.com/indutny/bn.js",
|
|
24
13
|
"bugs": {
|
|
25
14
|
"url": "https://github.com/indutny/bn.js/issues"
|
|
26
15
|
},
|
|
16
|
+
"repository": {
|
|
17
|
+
"type": "git",
|
|
18
|
+
"url": "git@github.com:indutny/bn.js"
|
|
19
|
+
},
|
|
20
|
+
"license": "MIT",
|
|
21
|
+
"author": "Fedor Indutny <fedor@indutny.com>",
|
|
27
22
|
"files": [
|
|
28
|
-
"lib"
|
|
23
|
+
"lib/bn.js"
|
|
29
24
|
],
|
|
30
|
-
"
|
|
25
|
+
"main": "lib/bn.js",
|
|
31
26
|
"browser": {
|
|
32
27
|
"buffer": false
|
|
33
28
|
},
|
|
29
|
+
"scripts": {
|
|
30
|
+
"lint": "standardx",
|
|
31
|
+
"test": "npm run lint && npm run unit",
|
|
32
|
+
"unit": "mocha --reporter=spec test/*-test.js"
|
|
33
|
+
},
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"babel-eslint": "^10.0.
|
|
36
|
-
"mocha": "^
|
|
37
|
-
"standardx": "^
|
|
35
|
+
"babel-eslint": "^10.0.3",
|
|
36
|
+
"mocha": "^7.0.1",
|
|
37
|
+
"standardx": "^5.0.0"
|
|
38
38
|
},
|
|
39
39
|
"standardx": {
|
|
40
40
|
"parser": "babel-eslint"
|