Skip to content

Commit c8b7f63

Browse files
authored
Fix currency launcher authority funding when not the main subsidizer (#167)
1 parent 8552871 commit c8b7f63

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

ocp/transaction/transaction.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -342,12 +342,12 @@ func MakeExternalTransferWithAuthorityTransaction(
342342
}
343343

344344
func MakeSolanaTransferTransaction(
345-
source, destination *common.Account,
345+
payer, source, destination *common.Account,
346346
lamports uint64,
347347
bh solana.Blockhash,
348348
) (solana.Transaction, error) {
349349
txn := solana.NewLegacyTransaction(
350-
common.GetSubsidizer().PublicKey().ToBytes(),
350+
payer.PublicKey().ToBytes(),
351351
compute_budget.SetComputeUnitPrice(10_000),
352352
compute_budget.SetComputeUnitLimit(1_000),
353353
system.Transfer(

ocp/worker/currency/launcher/util.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ func fundAuthority(ctx context.Context, data ocp_data.Provider, subsidizer, acco
204204
if err != nil {
205205
return errors.Wrap(err, "error getting latest blockhash")
206206
}
207-
txn, err := transaction_util.MakeSolanaTransferTransaction(subsidizer, account, amount, bh)
207+
txn, err := transaction_util.MakeSolanaTransferTransaction(subsidizer, subsidizer, account, amount, bh)
208208
if err != nil {
209209
return errors.Wrap(err, "error making solana transfer transaction")
210210
}

0 commit comments

Comments
 (0)