- add: logout grpc function
- add: logout packet handler - add: connection state and service for storing connection data - add: session service calls to auth-service - fix: compile error on database service due to moved redis cache
This commit is contained in:
@@ -34,12 +34,12 @@ const LoginPage = () => {
|
||||
const response = await axios.post(apiUrl, { username, password });
|
||||
|
||||
// Extract token and server info from response
|
||||
const { token, serverIp } = response.data;
|
||||
const { token, session_id } = response.data;
|
||||
|
||||
setMessage("Login successful! Launching game...");
|
||||
|
||||
const { ServiceAddress, ServicePort } = await getServiceAddress("packet-service");
|
||||
window.location.href = `osirose-launcher://launch?otp=${encodeURIComponent(token)}&ip=${encodeURIComponent(ServiceAddress)}&port=${encodeURIComponent(ServicePort)}&username=${encodeURIComponent(username)}`;
|
||||
window.location.href = `osirose-launcher://launch?otp=${encodeURIComponent(token)}&session=${encodeURIComponent(session_id)}&ip=${encodeURIComponent(ServiceAddress)}&port=${encodeURIComponent(ServicePort)}&username=${encodeURIComponent(username)}`;
|
||||
} catch (error) {
|
||||
setMessage("Login failed: " + error.response?.data?.error || error.message);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user