🐛 Fix authorize redirect
This commit is contained in:
@@ -157,7 +157,7 @@ function checkIfNewApp() {
|
|||||||
async function handleAuthorize() {
|
async function handleAuthorize() {
|
||||||
isAuthorizing.value = true
|
isAuthorizing.value = true
|
||||||
try {
|
try {
|
||||||
const data = await api<{ redirect_uri?: string }>(
|
const data = await api<{ redirectUri?: string }>(
|
||||||
"/id/auth/open/authorize",
|
"/id/auth/open/authorize",
|
||||||
{
|
{
|
||||||
method: "POST",
|
method: "POST",
|
||||||
@@ -165,8 +165,8 @@ async function handleAuthorize() {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
if (data.redirect_uri) {
|
if (data.redirectUri) {
|
||||||
window.location.href = data.redirect_uri
|
window.location.href = data.redirectUri
|
||||||
}
|
}
|
||||||
} catch (err: any) {
|
} catch (err: any) {
|
||||||
error.value = err.message || "An error occurred during authorization"
|
error.value = err.message || "An error occurred during authorization"
|
||||||
|
Reference in New Issue
Block a user