fix(web): fix infinite loop T_T

This commit is contained in:
rjindael 2023-08-01 21:28:25 -07:00
parent c48216c540
commit a5c94ba800
No known key found for this signature in database
GPG Key ID: D069369C906CCF31
1 changed files with 6 additions and 3 deletions

View File

@ -15,9 +15,12 @@ namespace Kiseki.Launcher
public static readonly HttpClient HttpClient = new();
public static string CurrentUrl { get; private set; } = "";
public static bool Initialize()
public static bool Initialize(bool setBaseUrl = true)
{
CurrentUrl = BASE_URL;
if (setBaseUrl)
{
CurrentUrl = BASE_URL;
}
int response = CheckHealth();
@ -26,7 +29,7 @@ namespace Kiseki.Launcher
if (response == RESPONSE_MAINTENANCE)
{
CurrentUrl = $"{MAINTENANCE_DOMAIN}.{BASE_URL}";
return Initialize();
return Initialize(false);
}
return false;