Update gate.html
Browse files
gate.html
CHANGED
|
@@ -46,10 +46,8 @@
|
|
| 46 |
<script>
|
| 47 |
lucide.createIcons();
|
| 48 |
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
const EMMYS_URL = "https://huggingface.co/spaces/YOUR_USER/emmys-portal"; // your portal URL
|
| 52 |
-
|
| 53 |
document.getElementById('gate').addEventListener('submit', async (e)=>{
|
| 54 |
e.preventDefault();
|
| 55 |
const btn = document.getElementById('go');
|
|
@@ -70,7 +68,7 @@
|
|
| 70 |
if(out.decision === "Access Granted"){
|
| 71 |
const score = Number(out.score || 0).toFixed(3);
|
| 72 |
const token = out.token ? `&token=${encodeURIComponent(out.token)}` : "";
|
| 73 |
-
|
| 74 |
window.location.href = `${EMMYS_URL}?user=${encodeURIComponent(name)}&score=${score}${token}`;
|
| 75 |
}else{
|
| 76 |
msg.textContent = `⛔ ${out.decision || "Denied"} — score=${Number(out.score||0).toFixed(3)}`;
|
|
|
|
| 46 |
<script>
|
| 47 |
lucide.createIcons();
|
| 48 |
|
| 49 |
+
const VERIFY_URL = "https://hudaakram-emmys-api.hf.space/verify";
|
| 50 |
+
const EMMYS_URL = "./index.html";
|
|
|
|
|
|
|
| 51 |
document.getElementById('gate').addEventListener('submit', async (e)=>{
|
| 52 |
e.preventDefault();
|
| 53 |
const btn = document.getElementById('go');
|
|
|
|
| 68 |
if(out.decision === "Access Granted"){
|
| 69 |
const score = Number(out.score || 0).toFixed(3);
|
| 70 |
const token = out.token ? `&token=${encodeURIComponent(out.token)}` : "";
|
| 71 |
+
|
| 72 |
window.location.href = `${EMMYS_URL}?user=${encodeURIComponent(name)}&score=${score}${token}`;
|
| 73 |
}else{
|
| 74 |
msg.textContent = `⛔ ${out.decision || "Denied"} — score=${Number(out.score||0).toFixed(3)}`;
|