Skip to content

Commit dfd3ac7

Browse files
committed
wip
1 parent 580e9f8 commit dfd3ac7

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

src/wallet.rs

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2479,15 +2479,13 @@ impl UserOperationBuilder {
24792479
signer: &S,
24802480
provider: &Provider,
24812481
) -> Result<(), WalletError> {
2482-
// Generate paymaster data with real permit signature
2483-
let paymaster_data = encode_usdc_paymaster_data_with_signer(
2482+
// Use simple Circle format - no permit signature needed
2483+
// The TBA has already approved the paymaster to spend USDC
2484+
let paymaster_data = encode_circle_paymaster_data(
24842485
paymaster,
2485-
token_address,
2486-
max_cost,
2487-
tba_address,
2488-
signer,
2489-
provider,
2490-
)?;
2486+
500_000, // Default verification gas limit
2487+
300_000, // Default call gas limit
2488+
);
24912489

24922490
// Set the combined paymaster and data
24932491
self.paymaster_and_data = paymaster_data;
@@ -2685,6 +2683,8 @@ pub fn get_usdc_permit_nonce(
26852683
}
26862684

26872685
/// Encode paymaster data for USDC payment with EIP-2612 permit signature
2686+
/// DEPRECATED - We don't use permit signatures anymore, only simple format
2687+
/*
26882688
pub fn encode_usdc_paymaster_data_with_signer<S: Signer>(
26892689
paymaster: EthAddress,
26902690
token_address: EthAddress,
@@ -2736,6 +2736,7 @@ pub fn encode_usdc_paymaster_data_with_signer<S: Signer>(
27362736
27372737
Ok(data)
27382738
}
2739+
*/
27392740

27402741
/// Encode paymaster data for USDC payment (keeping old function for compatibility)
27412742
/// This version uses a dummy signature and will fail with AA33
@@ -2846,6 +2847,8 @@ pub fn create_multicall_permit_and_execute(
28462847

28472848
/// Encode paymaster data for USDC payment with on-chain permit (for TBAs)
28482849
/// This version doesn't include a permit signature since TBAs will call permit on-chain
2850+
/// DEPRECATED - We only use the simple Circle format now
2851+
/*
28492852
pub fn encode_usdc_paymaster_data_for_tba(
28502853
paymaster: EthAddress,
28512854
token_address: EthAddress,
@@ -2874,3 +2877,4 @@ pub fn encode_usdc_paymaster_data_for_tba(
28742877
28752878
data
28762879
}
2880+
*/

0 commit comments

Comments
 (0)