MCPcopy Create free account
hub / github.com/JumpCrypto/sol-arc / AddComponents

Class AddComponents

programs/registry/src/context.rs:275–303  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

273#[derive(Accounts)]
274#[instruction(components: Vec<(Pubkey, SerializedComponent)>)]
275pub struct AddComponents<'info>{
276 #[account(mut)]
277 pub payer: Signer<'info>,
278 pub system_program: Program<'info, System>,
279
280 //Used to Sign Tx for the CPI
281 #[account(
282 seeds=[b"registry_signer"],
283 bump,
284 )]
285 pub registry_config: Account<'info, RegistryConfig>,
286
287 #[account(
288 mut,
289 constraint = entity.registry.key() == program_id.key() && action_bundle_registration.instances.contains(&entity.instance)
290 )]
291 pub entity: Box<Account<'info, Entity>>,
292
293 pub action_bundle: Signer<'info>,
294
295 // System is allowed to modify the component it's adding
296 // System is a signer
297 #[account(
298 constraint = action_bundle_registration.action_bundle.key() == action_bundle.key() && check_sys_registry(&components.iter().map(|tuple| tuple.0.clone() ).collect(), &action_bundle_registration.components)
299 )]
300 pub action_bundle_registration: Account<'info, ActionBundleRegistration>,
301
302 pub core_ds: Program<'info, CoreDs>,
303}
304
305#[derive(Accounts)]
306#[instruction(components: Vec<Pubkey>)]

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected