Skip to content

Commit

Permalink
fix client-version fallback not handling channel errors (#4378)
Browse files Browse the repository at this point in the history
  • Loading branch information
bluepilledgreat authored Jan 23, 2025
1 parent 5d1aa50 commit 4785464
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion Bloxstrap/RobloxInterfaces/Deployment.cs
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,15 @@ public static async Task<ClientVersion> GetInfo(string? channel = null)
App.Logger.WriteLine(LOG_IDENT, "Failed to contact clientsettingscdn! Falling back to clientsettings...");
App.Logger.WriteException(LOG_IDENT, ex);

clientVersion = await Http.GetJson<ClientVersion>("https://clientsettings.roblox.com" + path);
try
{
clientVersion = await Http.GetJson<ClientVersion>("https://clientsettings.roblox.com" + path);
}
catch (HttpRequestException httpEx)
when (!isDefaultChannel && BadChannelCodes.Contains(httpEx.StatusCode))
{
throw new InvalidChannelException(httpEx.StatusCode);
}
}

// check if channel is behind LIVE
Expand Down

0 comments on commit 4785464

Please sign in to comment.