Revert "feat: swap support usdc quote"

This reverts commit 9bb08bd567.
This commit is contained in:
tommggo
2025-10-08 21:04:50 +08:00
parent 9bb08bd567
commit d567477bdb
10 changed files with 94 additions and 181 deletions
+6 -8
View File
@@ -53,11 +53,10 @@ impl InstructionBuilder for PumpSwapInstructionBuilder {
let pool_base_token_account = protocol_params.pool_base_token_account;
let pool_quote_token_account = protocol_params.pool_quote_token_account;
// Only support WSOL or USDC as quote mint for now
if quote_mint != crate::constants::WSOL_TOKEN_ACCOUNT
&& quote_mint != crate::constants::USDC_TOKEN_ACCOUNT
if base_mint != crate::constants::WSOL_TOKEN_ACCOUNT
&& quote_mint != crate::constants::WSOL_TOKEN_ACCOUNT
{
return Err(anyhow!("Unsupported quote mint for PumpSwap"));
return Err(anyhow!("Invalid base mint and quote mint"));
}
// ========================================
@@ -220,11 +219,10 @@ impl InstructionBuilder for PumpSwapInstructionBuilder {
let base_token_program = protocol_params.base_token_program;
let quote_token_program = protocol_params.quote_token_program;
// Only support WSOL or USDC as quote mint for now
if quote_mint != crate::constants::WSOL_TOKEN_ACCOUNT
&& quote_mint != crate::constants::USDC_TOKEN_ACCOUNT
if base_mint != crate::constants::WSOL_TOKEN_ACCOUNT
&& quote_mint != crate::constants::WSOL_TOKEN_ACCOUNT
{
return Err(anyhow!("Unsupported quote mint for PumpSwap"));
return Err(anyhow!("Invalid base mint and quote mint"));
}
if params.input_amount.is_none() {
return Err(anyhow!("Token amount is not set"));