From 745d7f6b7f05d51bf6e5e34002bd12f7b4b9a911 Mon Sep 17 00:00:00 2001 From: Misha Gusev Date: Sun, 15 Sep 2024 16:33:31 +0300 Subject: [PATCH] Update main.js --- src/js/main.js | 41 ++++++++++++++++++++++++++++++++++++++--- 1 file changed, 38 insertions(+), 3 deletions(-) diff --git a/src/js/main.js b/src/js/main.js index 2f8e606..d03fc31 100644 --- a/src/js/main.js +++ b/src/js/main.js @@ -22,9 +22,11 @@ async function checkNickname(name) { const [nickname, tag] = name.split("#"); + const HDEV_key = hdevApiKey; + try { const response = await fetch( - `https://api.henrikdev.xyz/valorant/v1/account/${nickname}/${tag}`, + `https://api.henrikdev.xyz/valorant/v1/account/${nickname}/${tag}?api_key=${HDEV_key}`, ); if (response.status === 404) { alertText.innerHTML = `${name} not found.`; @@ -48,6 +50,7 @@ document.querySelector("#app").innerHTML = ` modal: false, alert: false, nickname: '', + hdevApiKey: '', infoContainer: true, contentContainer: false, generateContainer: false, @@ -140,6 +143,34 @@ document.querySelector("#app").innerHTML = ` +
+ + + + + + + +