async function searchResults(keyword) { const results = []; try { const response = await fetchv2("https://funmovieslix.com/?s=" + encodeURIComponent(keyword)); const html = await response.text(); const regex = /[\s\S]*?]+src="([^"]+)"[^>]*>[\s\S]*?

([^<]+)<\/h3>/g; let match; while ((match = regex.exec(html)) !== null) { results.push({ title: match[3].trim(), image: match[2].trim(), href: match[1].trim() }); } return JSON.stringify(results); } catch (err) { return JSON.stringify([{ title: "Error", image: "Error", href: "Error" }]); } } async function extractDetails(url) { try { const response = await fetchv2(url); const html = await response.text(); const descMatch = html.match(/
]*>[\s\S]*?

([\s\S]*?)<\/p>/); const description = descMatch ? descMatch[1].trim() : "N/A"; const dateMatch = html.match(/]*>S\d+\sEps?(\d+)<\/a>/g; let match; while ((match = regex.exec(html)) !== null) { results.push({ href: match[1].trim(), number: parseInt(match[2], 10) }); } if (results.length === 0) { results.push({ href: url, number: 1 }); } return JSON.stringify(results); } catch (err) { return JSON.stringify([{ href: "Error", number: "Error" }]); } } async function extractStreamUrl(url) { try { const response = await fetchv2(url); const html = await response.text(); const match = html.match(/