Created At: 2026-11-18T04:49:54Z
Completed At: 2026-11-18T04:49:54Z
Command exited with code 0.
Command output:
if (typeof invalidateUserCache === 'function') {
invalidateUserCache(payment.userId);
} else if (global.helpers && typeof global.helpers.invalidateUserCache === 'function') {
global.helpers.invalidateUserCache(payment.userId);
} else if (userCache) {
userCache.delete(`user_access:${payment.userId}`);
}
const planDays = Math.round((planDurations[planType] || 0) / (24 * 60 * 60 * 1000));
const successMsg = isPlanApplied
? `🔔 PLAN PURCHASE SUCCESSFUL 🔔\n` +
`━━━━━━━━━━━━━━━━━━━━━━━━━━\n` +
`Aapka plan upgrade successful ho gaya hai!\n\n` +
`🆔 Order ID: ${payment.orderId}\n` +
`💵 Amount Paid: ₹${payment.expectedAmount}\n` +
`💎 Unlimited Plan: ${planType.toUpperCase()} (${planDays} Days - Offer Applied! 🎁)\n` +
`📅 Expires At: ${planExpiryStr}\n` +
`━━━━━━━━━━━━━━━━━━━━━━━━━━\n` +
`✨ Premium features activate ho chuke hain. Aap query continue kar sakte hain.`
: `🔔 PAYMENT AUTO-CREDITED 🔔\n` +
`━━━━━━━━━━━━━━━━━━━━━━━━━━\n` +
`Aapka pending deposit successful ho gaya hai!\n\n` +
`🆔 Order ID: ${payment.orderId}\n` +
`💵 Amount Paid: ₹${payment.expectedAmount}\n` +
(creditCalc.bonusCredits > 0
? `🪙 Credits Added: ${creditCalc.totalCredits} Credits (Base: ${creditCalc.baseCredits} + 🎁 ${creditCalc.bonusCredits} Extra Offer) ${CREDIT_EMOJI}\n`
: `🪙 Credits Added: ${creditCalc.totalCredits} Credits ${CREDIT_EMOJI}\n`) +
`💰 New Wallet Balance: ${finalCredits} Credits ${CREDIT_EMOJI}\n` +
`━━━━━━━━━━━━━━━━━━━━━━━━━━\n` +
`✨ Premium features activate ho chuke hain. Aap query continue kar sakte hain.`;
await bot.telegram.sendMessage(payment.userId, successMsg, { parse_mode: 'HTML' }).catch(err => {
console.error(`[DAEMON] Failed to message user ${payment.userId}:`, err.message);
});
// --- Edit support group notification to SUCCESS ---
try {
const logGroupId = process.env.LOG_GROUP_ID;
if (logGroupId && payment.supportMsgId) {
const successIST = global.helpers.formatDateIST(new Date());
const successNotif = `✅ UTR VERIFIED — PAYMENT SUCCESSFUL\n` +