mirror of
https://github.com/fullstack-cash/bch-api.git
synced 2026-09-21 16:52:04 -07:00
Merge pull request #196 from Permissionless-Software-Foundation/ct-unstable
fix(body size): Increasing POST body size allowed
This commit is contained in:
+2
-2
@@ -90,8 +90,8 @@ const logStream = {
|
|||||||
}
|
}
|
||||||
app.use(logger(morganFormat, { stream: logStream }))
|
app.use(logger(morganFormat, { stream: logStream }))
|
||||||
|
|
||||||
app.use(bodyParser.json())
|
app.use(bodyParser.json({ limit: '50mb' }))
|
||||||
app.use(bodyParser.urlencoded({ extended: false }))
|
app.use(bodyParser.urlencoded({ extended: false, limit: '50mb' }))
|
||||||
app.use(cookieParser())
|
app.use(cookieParser())
|
||||||
app.use(express.static(path.join(__dirname, 'public')))
|
app.use(express.static(path.join(__dirname, 'public')))
|
||||||
|
|
||||||
|
|||||||
@@ -16,7 +16,6 @@ const config = require('../../../config')
|
|||||||
const routeUtils = new RouteUtils()
|
const routeUtils = new RouteUtils()
|
||||||
const bchjs = new BCHJS({ restURL: config.restURL })
|
const bchjs = new BCHJS({ restURL: config.restURL })
|
||||||
|
|
||||||
|
|
||||||
let _this
|
let _this
|
||||||
|
|
||||||
class PsfSlpIndexer {
|
class PsfSlpIndexer {
|
||||||
@@ -315,8 +314,9 @@ class PsfSlpIndexer {
|
|||||||
// console.log(`mdaTxs: ${JSON.stringify(mdaTxs, null, 2)}`)
|
// console.log(`mdaTxs: ${JSON.stringify(mdaTxs, null, 2)}`)
|
||||||
|
|
||||||
let data = false
|
let data = false
|
||||||
// Maps each transaction of the mutableDataAddr
|
// Maps each transaction of the mutableDataAddr.
|
||||||
// if finds an OP_RETURN decode is and closes the loop
|
// If it finds an OP_RETURN, decode it. Exit the loop once the first
|
||||||
|
// valid mutable data entry is found.
|
||||||
// Start with the newest TXID entry and scan the history to find the first
|
// Start with the newest TXID entry and scan the history to find the first
|
||||||
// entry with an IPFS CID.
|
// entry with an IPFS CID.
|
||||||
for (let i = mdaTxs.length - 1; i > -1; i--) {
|
for (let i = mdaTxs.length - 1; i > -1; i--) {
|
||||||
@@ -345,7 +345,7 @@ class PsfSlpIndexer {
|
|||||||
|
|
||||||
// Skip entry if it was not made by the MDA private key.
|
// Skip entry if it was not made by the MDA private key.
|
||||||
if (mutableDataAddr !== vinAddress) {
|
if (mutableDataAddr !== vinAddress) {
|
||||||
console.log('Data is not generated by MDA')
|
console.log('Data is not generated by MDA, skipping.')
|
||||||
data = false
|
data = false
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user