Skip to content

Commit

Permalink
Make can_skip_build query parameter have value.
Browse files Browse the repository at this point in the history
The hub sends a can_skip_build parameter to indicate ACZ doesn't need to be built. Well I sent it without value originally because I figured that wasn't necessary to indicate boolean state.

Wow I made the critical mistake of trusting a 150 upvote Stack Overflow answer saying that's valid.

According to Stack Overflow this should be "totally valid" but what they fail to mention is that "totally valid" means "there is no spec for or against" which means that "does your server-side framework sanely support it" is not really guaranteed. Making a Stack Overflow answer like this is just irresponsible Jesus Christ.
  • Loading branch information
PJB3005 committed Dec 16, 2023
1 parent a3dbc19 commit abdfec0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion SS14.ServerHub/Controllers/ServerListController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ private async Task<(IActionResult? result, byte[]? statusJson, byte[]? infoJson)
try
{
var uriBuilder = new UriBuilder(Ss14UriHelper.GetServerInfoAddress(uri));
uriBuilder.Query = "?can_skip_build";
uriBuilder.Query = "?can_skip_build=1";
infoResponse = await _httpClient.GetLimitedJsonResponseBody(
new Uri(uriBuilder.ToString()),
maxInfoSize * 1024,
Expand Down

0 comments on commit abdfec0

Please sign in to comment.