@net-protocol/cli 0.1.44 → 0.1.45
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/dist/cli/index.mjs +22 -21
- package/dist/cli/index.mjs.map +1 -1
- package/dist/feed/index.mjs +22 -21
- package/dist/feed/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/cli/index.mjs
CHANGED
|
@@ -7313,16 +7313,15 @@ async function executeFeedVerifyClaim(txHash, options) {
|
|
|
7313
7313
|
});
|
|
7314
7314
|
const netContract = getNetContract(readOnlyOptions.chainId);
|
|
7315
7315
|
const netClient = createNetClient(readOnlyOptions);
|
|
7316
|
-
const
|
|
7317
|
-
|
|
7318
|
-
|
|
7319
|
-
|
|
7320
|
-
|
|
7321
|
-
|
|
7322
|
-
|
|
7323
|
-
)
|
|
7324
|
-
|
|
7325
|
-
return;
|
|
7316
|
+
const wasAlreadyRecorded = getHistory().some(
|
|
7317
|
+
(entry) => entry.txHash === txHash
|
|
7318
|
+
);
|
|
7319
|
+
if (wasAlreadyRecorded && !options.json) {
|
|
7320
|
+
console.log(
|
|
7321
|
+
chalk4.yellow(
|
|
7322
|
+
"Transaction already in history \u2014 re-deriving URLs from on-chain data."
|
|
7323
|
+
)
|
|
7324
|
+
);
|
|
7326
7325
|
}
|
|
7327
7326
|
const receipt = await publicClient.getTransactionReceipt({ hash: txHash }).catch(
|
|
7328
7327
|
() => exitWithError(
|
|
@@ -7405,15 +7404,18 @@ async function executeFeedVerifyClaim(txHash, options) {
|
|
|
7405
7404
|
postId = createPostId(message);
|
|
7406
7405
|
permalink = postPermalink(readOnlyOptions.chainId, { globalIndex });
|
|
7407
7406
|
}
|
|
7408
|
-
|
|
7409
|
-
|
|
7410
|
-
|
|
7411
|
-
|
|
7412
|
-
|
|
7413
|
-
|
|
7414
|
-
|
|
7415
|
-
|
|
7416
|
-
|
|
7407
|
+
if (!wasAlreadyRecorded) {
|
|
7408
|
+
addHistoryEntry({
|
|
7409
|
+
type,
|
|
7410
|
+
txHash,
|
|
7411
|
+
chainId: readOnlyOptions.chainId,
|
|
7412
|
+
feed: feedName,
|
|
7413
|
+
sender: message.sender,
|
|
7414
|
+
text: message.text,
|
|
7415
|
+
postId: type === "comment" ? parentPostId : postId
|
|
7416
|
+
});
|
|
7417
|
+
recorded++;
|
|
7418
|
+
}
|
|
7417
7419
|
const entry = {
|
|
7418
7420
|
type,
|
|
7419
7421
|
txHash,
|
|
@@ -7449,10 +7451,9 @@ async function executeFeedVerifyClaim(txHash, options) {
|
|
|
7449
7451
|
Tx: ${txHash}`;
|
|
7450
7452
|
console.log(chalk4.green(` ${label}`));
|
|
7451
7453
|
}
|
|
7452
|
-
recorded++;
|
|
7453
7454
|
}
|
|
7454
7455
|
if (options.json) {
|
|
7455
|
-
printJson({ recorded, entries });
|
|
7456
|
+
printJson({ alreadyRecorded: wasAlreadyRecorded, recorded, entries });
|
|
7456
7457
|
return;
|
|
7457
7458
|
}
|
|
7458
7459
|
if (recorded > 0) {
|