🐛 Fix sdkTwittertogin

This commit is contained in:
xtaodada 2022-05-14 13:08:02 +08:00
parent 309b9ceffb
commit 7cbbd770a5
Signed by: xtaodada
GPG Key ID: 4CBB3F4FA8C85659

View File

@ -8,6 +8,7 @@ import com.xtaolabs.gcauth_oauth.handler.JsonHandler;
import com.xtaolabs.gcauth_oauth.handler.VerifyHandler; import com.xtaolabs.gcauth_oauth.handler.VerifyHandler;
import com.xtaolabs.gcauth_oauth.handler.RequestHandler; import com.xtaolabs.gcauth_oauth.handler.RequestHandler;
import emu.grasscutter.server.dispatch.DispatchHttpJsonHandler;
import express.Express; import express.Express;
import io.javalin.http.staticfiles.Location; import io.javalin.http.staticfiles.Location;
@ -41,6 +42,10 @@ public class GCAuth_OAuth extends Plugin {
app.get("/Api/twitter_login", new JsonHandler()); app.get("/Api/twitter_login", new JsonHandler());
app.get("/sdkTwitterLogin.html", new DispatchHttpJsonHandler(
"<meta http-equiv=\"refresh\" content=\"0;url=https://account.mihoyo.com/gcauth_oauth/login.html\">"
));
app.post("/gcauth_oauth/login", new RequestHandler()); app.post("/gcauth_oauth/login", new RequestHandler());
app.post("/hk4e_global/mdk/shield/api/loginByThirdparty", new VerifyHandler()); app.post("/hk4e_global/mdk/shield/api/loginByThirdparty", new VerifyHandler());