Closed stegaBOB closed 1 year ago
The clock account is unused. It currently takes up compute and txn size by including it in the transaction. Save space and compute by replacing it with an unchecked account
What do you mean? Seems like it's used only in mint.rs
and can't be removed there.
candy-machine/program/src/processor/mint.rs: clock::Clock,
candy-machine/program/src/processor/mint.rs: clock: Sysvar<'info, Clock>,
candy-machine/program/src/processor/mint.rs: let clock = Clock::get()?;
candy-machine/program/src/processor/mint.rs: if clock.unix_timestamp > es.number as i64
candy-machine/program/src/processor/mint.rs: if clock.unix_timestamp < val
candy-machine/program/src/processor/mint.rs: let go_live = assert_valid_go_live(payer, &clock, candy_machine);
candy-machine/program/src/processor/mint.rs: let go_live = assert_valid_go_live(payer, &clock, candy_machine);
candy-machine/program/src/processor/mint.rs: let go_live = assert_valid_go_live(payer, &clock, candy_machine);
candy-machine/program/src/processor/mint.rs: if freeze_pda.thaw_eligible(clock.unix_timestamp, candy_machine) {
candy-machine/program/src/processor/mint.rs: if freeze_pda.thaw_eligible(clock.unix_timestamp, candy_machine) {
candy-machine/program/src/processor/mint.rs: freeze_pda.mint_start = Some(clock.unix_timestamp);
candy-machine/program/src/utils.rs: clock::Clock,
candy-machine/program/src/utils.rs: clock: &Clock,
candy-machine/program/src/utils.rs: if clock.unix_timestamp < val && !cmp_pubkeys(payer.key, &candy_machine.authority) {
think this is not needed?
The clock account is unused. It currently takes up compute and txn size by including it in the transaction. Save space and compute by replacing it with an unchecked account