We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents dfc55a9 + 8f86e17 commit 132b08bCopy full SHA for 132b08b
src/index.ts
@@ -25,7 +25,12 @@ const swap = async () => {
25
* Find pool information for the given token pair.
26
*/
27
const poolInfo = raydiumSwap.findPoolInfoForTokens(swapConfig.tokenAAddress, swapConfig.tokenBAddress);
28
- console.log('Found pool info');
+ if (!poolInfo) {
29
+ console.error('Pool info not found');
30
+ return 'Pool info not found';
31
+ } else {
32
+ console.log('Found pool info');
33
+ }
34
35
/**
36
* Prepare the swap transaction with the given parameters.
0 commit comments