File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -2282,19 +2282,20 @@ pub struct UserOperationBuilder {
2282
2282
}
2283
2283
2284
2284
impl UserOperationBuilder {
2285
- /// Create a new UserOperation builder
2285
+ /// Create a new UserOperationBuilder with defaults
2286
2286
pub fn new ( sender : EthAddress , chain_id : u64 ) -> Self {
2287
2287
Self {
2288
2288
sender,
2289
2289
nonce : U256 :: ZERO ,
2290
- init_code : vec ! [ ] ,
2291
- call_data : vec ! [ ] ,
2290
+ init_code : Vec :: new ( ) ,
2291
+ call_data : Vec :: new ( ) ,
2292
2292
call_gas_limit : U256 :: from ( 100_000 ) ,
2293
2293
verification_gas_limit : U256 :: from ( 150_000 ) ,
2294
2294
pre_verification_gas : U256 :: from ( 21_000 ) ,
2295
- max_fee_per_gas : U256 :: ZERO ,
2296
- max_priority_fee_per_gas : U256 :: ZERO ,
2297
- paymaster_and_data : vec ! [ ] ,
2295
+ // Set reasonable gas prices for Base chain
2296
+ max_fee_per_gas : U256 :: from ( 50_000_000 ) , // 0.05 gwei
2297
+ max_priority_fee_per_gas : U256 :: from ( 50_000_000 ) , // 0.05 gwei
2298
+ paymaster_and_data : Vec :: new ( ) ,
2298
2299
chain_id,
2299
2300
}
2300
2301
}
You can’t perform that action at this time.
0 commit comments