fix(bch-js): Updating to v4.15.2 to test rate limit idea

This commit is contained in:
Chris Troutner
2021-02-24 13:36:21 -08:00
parent 36dd64db22
commit 96f1cb6ad4
3 changed files with 336 additions and 1228 deletions
+330 -1225
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -29,7 +29,7 @@
"node": ">=10.15.1" "node": ">=10.15.1"
}, },
"dependencies": { "dependencies": {
"@psf/bch-js": "^4.11.1", "@psf/bch-js": "^4.15.2",
"apidoc": "^0.26.0", "apidoc": "^0.26.0",
"axios": "^0.21.1", "axios": "^0.21.1",
"bitcore-lib-cash": "^8.23.1", "bitcore-lib-cash": "^8.23.1",
@@ -69,7 +69,7 @@
"nock": "^13.0.5", "nock": "^13.0.5",
"nyc": "^15.0.0", "nyc": "^15.0.0",
"prettier": "^2.0.0", "prettier": "^2.0.0",
"semantic-release": "^17.3.1", "semantic-release": "^17.3.9",
"sinon": "^9.0.0", "sinon": "^9.0.0",
"standard": "^14.3.1" "standard": "^14.3.1"
}, },
+4 -1
View File
@@ -1979,6 +1979,9 @@ class Slp {
try { try {
const utxos = req.body.utxos const utxos = req.body.utxos
console.log(`req._remoteAddress: ${req._remoteAddress}`)
const origin = req._remoteAddress
// Validate inputs // Validate inputs
if (!Array.isArray(utxos)) { if (!Array.isArray(utxos)) {
res.status(422) res.status(422)
@@ -2013,7 +2016,7 @@ class Slp {
const theseUtxos = utxos[i].utxos const theseUtxos = utxos[i].utxos
// Get SLP token details. // Get SLP token details.
const details = await _this.bchjs.SLP.Utils.tokenUtxoDetails(theseUtxos) const details = await _this.bchjs.SLP.Utils.tokenUtxoDetails(theseUtxos, origin)
// console.log('details: ', details) // console.log('details: ', details)
// Replace the original UTXO data with the hydrated data. // Replace the original UTXO data with the hydrated data.