mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-11-06 12:52:26 +00:00
Merge pull request #307 from PR0M3TH3AN/codex/fix-amount-not-defined-error-on-zap
Fix channel zap share amount tracking
This commit is contained in:
1 file changed
+4
-4
@@ -556,7 +556,7 @@ function createZapDependencies({ creatorEntry, platformEntry, shares, shareTrack
|
||||
},
|
||||
sendPayment: async (bolt11, params) => {
|
||||
const shareType = activeShare || "unknown";
|
||||
const amount =
|
||||
const shareAmount =
|
||||
shareType === "platform"
|
||||
? shares.platformShare
|
||||
: shares.creatorShare;
|
||||
@@ -570,7 +570,7 @@ function createZapDependencies({ creatorEntry, platformEntry, shares, shareTrack
|
||||
shareTracker.push({
|
||||
type: shareType,
|
||||
status: "success",
|
||||
amount,
|
||||
amount: shareAmount,
|
||||
address,
|
||||
payment,
|
||||
});
|
||||
@@ -581,7 +581,7 @@ function createZapDependencies({ creatorEntry, platformEntry, shares, shareTrack
|
||||
shareTracker.push({
|
||||
type: shareType,
|
||||
status: "error",
|
||||
amount,
|
||||
amount: shareAmount,
|
||||
address,
|
||||
error,
|
||||
});
|
||||
@@ -590,7 +590,7 @@ function createZapDependencies({ creatorEntry, platformEntry, shares, shareTrack
|
||||
"wallet.sendPayment",
|
||||
{
|
||||
shareType,
|
||||
amount,
|
||||
amount: shareAmount,
|
||||
address,
|
||||
tracker: shareTracker,
|
||||
context: { shares },
|
||||
|
||||
Reference in new issue
Block a user