INNER CODE UNIT · TypeScript
reserve_wallet_check
Deezzir/solana-bot · src/bot.ts:42
function reserve_wallet_check(wallets: common.Wallet[]) {
if (!common.check_reserve_exists(wallets)) {
common.error(common.red('Reserve wallet not found.'));
exit(1);
}
}
async function get_wallets_from_file(file: string): Promise<common.Wallet[]> {
try {
const wallets = await common.get_wallets(file);
if (wallets.length === 0) common.error(common.yellow('The file does not contain any wallets.'));
return wallets;
} catch (error) {
common.error(common.yellow(`${error}`));
}
return [];
}