Open bestotssyn opened 1 year ago
Your fix didn't work for me
You probably did something wrong, that makes it so if the request from Tebex's API return a nil value (basically if that transaction id doesn't exist, then it returns an embed that tells you that the transaction id is not found,
You can fix it by adding this in src/commands/tebex/lookup.js, right after:
const info = await getTransaction.json();
So after that line you add this:
if (info.packages === null || info.packages === undefined) { const errorEmbed = new EmbedBuilder() .setColor(0x0ab8f2) .setAuthor({ name: "Error"}) .setDescription(
Transaction ID \
${tid}` not found`); return await interaction.editReply({ embeds: [errorEmbed] }); }it will make it so if the transaction ID is invalid it will return from the function and send an embed that the Transcation ID is invalid.