mirror of
https://github.com/Grasscutters/GrassClipper.git
synced 2024-08-14 13:11:48 +08:00
change auth endpoints
This commit is contained in:
parent
344fcddb88
commit
574b2f4f09
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"applicationId": "js.grassclipper.app",
|
"applicationId": "js.grassclipper.app",
|
||||||
"version": "0.8.5",
|
"version": "0.8.6",
|
||||||
"resourcesURL": "https://github.com/Grasscutters/GrassClipper/releases/latest/download/resources.neu"
|
"resourcesURL": "https://github.com/Grasscutters/GrassClipper/releases/latest/download/resources.neu"
|
||||||
}
|
}
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"applicationId": "js.grassclipper.app",
|
"applicationId": "js.grassclipper.app",
|
||||||
"version": "0.8.5",
|
"version": "0.8.6",
|
||||||
"defaultMode": "window",
|
"defaultMode": "window",
|
||||||
"port": 0,
|
"port": 0,
|
||||||
"documentRoot": "/resources/",
|
"documentRoot": "/resources/",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "grassclipper",
|
"name": "grassclipper",
|
||||||
"version": "0.8.5",
|
"version": "0.8.6",
|
||||||
"repository": "https://github.com/Grasscutters/GrassClipper.git",
|
"repository": "https://github.com/Grasscutters/GrassClipper.git",
|
||||||
"author": "SpikeHD <spikegdofficial@gmail.com>",
|
"author": "SpikeHD <spikegdofficial@gmail.com>",
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
|
@ -298,9 +298,9 @@ async function openLogin() {
|
|||||||
|
|
||||||
// Check if we even need to authenticate
|
// Check if we even need to authenticate
|
||||||
try {
|
try {
|
||||||
const { data } = await axios.get(url + '/grasscutter/auth_status')
|
const { data } = await axios.get(url + '/authentication/type')
|
||||||
|
|
||||||
if (data?.message !== 'AUTH_ENABLED') {
|
if (!data.includes('GCAuthAuthenticationHandler')) {
|
||||||
launchPrivate()
|
launchPrivate()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -309,7 +309,6 @@ async function openLogin() {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
loginIpDisplay.innerText = ip
|
loginIpDisplay.innerText = ip
|
||||||
registerIpDisplay.innerText = ip
|
registerIpDisplay.innerText = ip
|
||||||
|
|
||||||
|
@ -62,7 +62,7 @@ async function login() {
|
|||||||
password,
|
password,
|
||||||
}
|
}
|
||||||
|
|
||||||
const { data } = await axios.post(url + '/grasscutter/login', reqBody)
|
const { data } = await axios.post(url + '/authentication/login', reqBody)
|
||||||
|
|
||||||
switch(data.message) {
|
switch(data.message) {
|
||||||
case 'INVALID_ACCOUNT':
|
case 'INVALID_ACCOUNT':
|
||||||
@ -117,7 +117,7 @@ async function register() {
|
|||||||
password_confirmation
|
password_confirmation
|
||||||
}
|
}
|
||||||
|
|
||||||
const { data } = await axios.post(url + '/grasscutter/register', reqBody)
|
const { data } = await axios.post(url + '/authentication/register', reqBody)
|
||||||
|
|
||||||
switch(data.message) {
|
switch(data.message) {
|
||||||
case 'USERNAME_TAKEN':
|
case 'USERNAME_TAKEN':
|
||||||
|
Loading…
x
Reference in New Issue
Block a user