<% function isValidYouTubeID(v) { return /^[a-zA-Z0-9_-]{11}$/.test(v); } function isLetterSpam(v) { return /^(.)\1+$/.test(v); } let reason; if (!isValidYouTubeID(v) || isLetterSpam(v)) { reason = "Video not found >~<"; } else { reason = "Poke is Switching VPN location right now - we dont know how long it will gonna take tho - it can be 10 minutes or 1 hour, its gonna retry until it founds a working server."; } %> <%- include('./layouts/error-video.ejs', { error: "loading failed :c", description: `${reason}` }) %>