chg: move formation of path to end
MODIFY
src/common/ExitManager.ts
src/common/ExitManager.ts
@@ -131,7 +131,7 @@ export default class ExitManager extends ContractsBase {
ethUtils.bufferToHex(receiptsRoot),
ethUtils.bufferToHex(receipt),
ethUtils.bufferToHex(ethUtils.rlp.encode(receiptParentNodes)),
- ethUtils.bufferToHex(path),
+ ethUtils.bufferToHex(Buffer.concat([Buffer.from('00', 'hex'), path])),
logIndex,
])
)

MODIFY
src/libs/ProofsUtil.ts
src/libs/ProofsUtil.ts
@@ -168,7 +168,7 @@ export default class ProofsUtil {
blockHash: ethUtils.toBuffer(receipt.blockHash),
parentNodes: stack.map(s => s.raw),
root: ProofsUtil.getRawHeader(block).receiptTrie,
- path: Buffer.concat([Buffer.from('00', 'hex'), rlp.encode(receipt.transactionIndex)]),
+ path: rlp.encode(receipt.transactionIndex),
value: rlp.decode(rawReceiptNode.value),
}
resolve(prf)

chg: move formation of path to end