From abdfec013f723eb1b6ea844bc7d409de64462792 Mon Sep 17 00:00:00 2001 From: Pieter-Jan Briers Date: Sat, 16 Dec 2023 16:59:31 +0100 Subject: [PATCH] Make can_skip_build query parameter have value. 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. --- SS14.ServerHub/Controllers/ServerListController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SS14.ServerHub/Controllers/ServerListController.cs b/SS14.ServerHub/Controllers/ServerListController.cs index 0f2060e..0f2e0e3 100644 --- a/SS14.ServerHub/Controllers/ServerListController.cs +++ b/SS14.ServerHub/Controllers/ServerListController.cs @@ -182,7 +182,7 @@ parsedAddress.Scheme is not (Ss14UriHelper.SchemeSs14 or Ss14UriHelper.SchemeSs1 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,