diff --git a/actions/createLUTproposal.ts b/actions/createLUTproposal.ts index ace0a4705f..50c779e5ac 100644 --- a/actions/createLUTproposal.ts +++ b/actions/createLUTproposal.ts @@ -10,10 +10,8 @@ import { TokenOwnerRecord, VoteType, withCreateProposal, - getSignatoryRecordAddress, withInsertTransaction, withSignOffProposal, - withAddSignatory, RpcContext, } from '@solana/spl-governance' import { @@ -94,24 +92,12 @@ export const createLUTProposal = async ( payer, plugin?.voterWeightPk ) - - await withAddSignatory( - instructions, - programId, - programVersion, - proposalAddress, - tokenOwnerRecord.pubkey, - governanceAuthority, - signatory, - payer - ) - - // TODO: Return signatoryRecordAddress from the SDK call + /* const signatoryRecordAddress = await getSignatoryRecordAddress( programId, proposalAddress, signatory - ) + ) */ const insertInstructions: TransactionInstruction[] = [] @@ -159,8 +145,8 @@ export const createLUTProposal = async ( governance, proposalAddress, signatory, - signatoryRecordAddress, - undefined + undefined, //signatoryRecordAddress, + tokenOwnerRecord.pubkey ) } diff --git a/actions/createProposal.ts b/actions/createProposal.ts index 82b5eb6ee1..1c29e2ed27 100644 --- a/actions/createProposal.ts +++ b/actions/createProposal.ts @@ -7,12 +7,10 @@ import { TokenOwnerRecord, VoteType, withCreateProposal, - getSignatoryRecordAddress, RpcContext, withInsertTransaction, InstructionData, withSignOffProposal, - withAddSignatory, MultiChoiceType, } from '@solana/spl-governance' import { @@ -76,7 +74,6 @@ export const createProposal = async ( const instructions: TransactionInstruction[] = [] const createNftTicketsIxs: TransactionInstruction[] = [] const governanceAuthority = walletPubkey - const signatory = walletPubkey const payer = walletPubkey const prerequisiteInstructions: TransactionInstruction[] = [] const prerequisiteInstructionsSigners: (Keypair | null)[] = [] @@ -131,24 +128,6 @@ export const createProposal = async ( plugin?.voterWeightPk ) - await withAddSignatory( - instructions, - programId, - programVersion, - proposalAddress, - tokenOwnerRecord.pubkey, - governanceAuthority, - signatory, - payer - ) - - // TODO: Return signatoryRecordAddress from the SDK call - const signatoryRecordAddress = await getSignatoryRecordAddress( - programId, - proposalAddress, - signatory - ) - const insertInstructions: TransactionInstruction[] = [] const chunkBys = instructionsData @@ -194,9 +173,9 @@ export const createProposal = async ( realm.pubkey, governance, proposalAddress, - signatory, - signatoryRecordAddress, - undefined + walletPubkey, + undefined, + tokenOwnerRecord.pubkey ) } diff --git a/cli/helpers/createBase64Proposal.ts b/cli/helpers/createBase64Proposal.ts index db9fc3608c..003de2e804 100644 --- a/cli/helpers/createBase64Proposal.ts +++ b/cli/helpers/createBase64Proposal.ts @@ -1,13 +1,11 @@ import { getGovernanceProgramVersion, getInstructionDataFromBase64, - getSignatoryRecordAddress, ProgramAccount, SYSTEM_PROGRAM_ID, TokenOwnerRecord, VoteType, WalletSigner, - withAddSignatory, withCreateProposal, withInsertTransaction, withSignOffProposal, @@ -101,23 +99,12 @@ export const createBase64Proposal = async ( payer, voterWeightPluginPk ) - - await withAddSignatory( - instructions, - governanceProgram, - programVersion, - proposalAddress, - tokenOwnerRecord.pubkey, - governanceAuthority, - signatory, - payer - ) - + /* const signatoryRecordAddress = await getSignatoryRecordAddress( governanceProgram, proposalAddress, signatory - ) + ) */ const insertInstructions: TransactionInstruction[] = [] for (const i in base64Instructions) { const instruction = getInstructionDataFromBase64(base64Instructions[i]) @@ -144,8 +131,8 @@ export const createBase64Proposal = async ( governance, proposalAddress, signatory, - signatoryRecordAddress, - undefined + undefined, //signatoryRecordAddress, + tokenOwnerRecord.pubkey ) const txChunks = chunk([...instructions, ...insertInstructions], 2)