aboutsummaryrefslogtreecommitdiff
path: root/chat/apiNew.js
diff options
context:
space:
mode:
authorNinjune <enderknight537@gmail.com>2023-01-14 18:51:28 -0600
committerNinjune <enderknight537@gmail.com>2023-01-14 18:51:28 -0600
commit8fa7fe39d9edbdd8b00ec238c4e40b6ecd0808cc (patch)
tree04000ede45a86ebfb76b5b01ad4a169be8234470 /chat/apiNew.js
parent329dccf50ed5e9f87531580f679522238b6a019b (diff)
downloadcoleweight-8fa7fe39d9edbdd8b00ec238c4e40b6ecd0808cc.tar.gz
coleweight-8fa7fe39d9edbdd8b00ec238c4e40b6ecd0808cc.tar.bz2
coleweight-8fa7fe39d9edbdd8b00ec238c4e40b6ecd0808cc.zip
v1.8.7HEADmain
Diffstat (limited to 'chat/apiNew.js')
-rw-r--r--chat/apiNew.js8
1 files changed, 3 insertions, 5 deletions
diff --git a/chat/apiNew.js b/chat/apiNew.js
index 76a2418..36025e3 100644
--- a/chat/apiNew.js
+++ b/chat/apiNew.js
@@ -7,13 +7,11 @@ register("chat", (key) => {
axios.get(`https://api.hypixel.net/key?key=${key}`)
.then(res => {
if(res.data.success == true)
- {
- constants.data.api_key = key
- constants.data.save()
ChatLib.chat(`${PREFIX}&aSuccsessfully set api key!`)
- }
else
- ChatLib.chat(`${PREFIX}&eKey is not valid!`)
+ ChatLib.chat(`${PREFIX}&eKey might not be valid!`)
+ constants.data.api_key = key
+ constants.data.save()
})
.catch(err => {
ChatLib.chat(`${PREFIX}&eKey is not valid! if this is a mistake report: ${err}`)