psffpp 1.1.6 → 1.1.7
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/LICENSE.md +1 -1
- package/index.js +4 -1
- package/package.json +1 -1
- package/test/unit/main-index-unit.js +1 -0
package/LICENSE.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
The MIT License (MIT)
|
|
2
|
-
Copyright (c) 2023 Chris Troutner <chris.troutner@gmail.com>
|
|
2
|
+
Copyright (c) 2023-2024 Chris Troutner <chris.troutner@gmail.com>
|
|
3
3
|
|
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
5
5
|
|
package/index.js
CHANGED
|
@@ -167,7 +167,10 @@ class PSFFPP {
|
|
|
167
167
|
console.log(`Burning ${actualCost} PSF tokens for ${fileSizeInMegabytes} MB of data.`)
|
|
168
168
|
|
|
169
169
|
const pobTxid = await this.wallet.burnTokens(actualCost, PSF_TOKEN_ID)
|
|
170
|
-
// console.log(`Proof-of-burn TX: ${
|
|
170
|
+
// console.log(`Proof-of-burn TX: ${pobT xid}`)
|
|
171
|
+
|
|
172
|
+
// Wait for the indexer to update before get utxos.
|
|
173
|
+
await this.bchjs.Util.sleep(4000)
|
|
171
174
|
|
|
172
175
|
// Get a UTXO to spend to generate the pin claim TX.
|
|
173
176
|
let utxos = await this.wallet.getUtxos()
|
package/package.json
CHANGED
|
@@ -110,6 +110,7 @@ describe('#PSFFPP-index.js', () => {
|
|
|
110
110
|
|
|
111
111
|
// Mock dependencies and force desired code path
|
|
112
112
|
sandbox.stub(uut, 'getMcWritePrice').resolves(0.08335233)
|
|
113
|
+
sandbox.stub(uut.bchjs.Util, 'sleep').resolves(true)
|
|
113
114
|
|
|
114
115
|
const inObj = {
|
|
115
116
|
cid: 'bafkreih7eeixbkyvabqdde4g5mdourjidxpsgf6bgz6f7ouxqr24stg6f4',
|