File tree Expand file tree Collapse file tree
basics/cross-program-invocation/native/programs/lever Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ cpi = ["no-entrypoint"]
99
1010[dependencies ]
1111borsh = " 1.5.7"
12- borsh-derive = " 0.10"
1312solana-program = " 2.0"
1413
1514[lib ]
Original file line number Diff line number Diff line change 1- use borsh:: { BorshDeserialize , BorshSerialize } ;
1+ use borsh:: { to_vec , BorshDeserialize , BorshSerialize } ;
22#[ cfg( not( feature = "no-entrypoint" ) ) ]
33use solana_program:: entrypoint;
44use solana_program:: {
@@ -42,7 +42,7 @@ pub fn initialize(
4242 let user = next_account_info ( accounts_iter) ?;
4343 let system_program = next_account_info ( accounts_iter) ?;
4444
45- let account_span = ( power_status . try_to_vec ( ) ? ) . len ( ) ;
45+ let account_span = ( to_vec ( & power_status ) ) ? . len ( ) ;
4646 let lamports_required = ( Rent :: get ( ) ?) . minimum_balance ( account_span) ;
4747
4848 invoke (
You can’t perform that action at this time.
0 commit comments