Skip to content

Commit 952ca57

Browse files
authored
Merge pull request #148 from RLBot/trim-aid
2 parents 19450b1 + 5dc9767 commit 952ca57

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

RLBotCS/ManagerTools/ConfigValidator.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ bool surpressWarnings
8787
{
8888
case CustomBotT bot:
8989
bot.AgentId ??= "";
90+
bot.AgentId = bot.AgentId.Trim();
9091
if (bot.AgentId == "")
9192
{
9293
Logger.LogError(
@@ -225,6 +226,7 @@ private static bool ValidateScripts(
225226
var script = scripts[i];
226227

227228
script.AgentId ??= "";
229+
script.AgentId = script.AgentId.Trim();
228230
if (script.AgentId == "")
229231
{
230232
Logger.LogError(

RLBotCS/Server/FlatBuffersSession.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ private async Task<bool> ParseClientMessage(InterfacePacket msg)
126126
case InterfaceMessage.ConnectionSettings when !_connectionEstablished:
127127
var readyMsg = msg.MessageAsConnectionSettings();
128128

129-
_agentId = readyMsg.AgentId ?? "";
129+
_agentId = (readyMsg.AgentId ?? "").Trim();
130130
_wantsBallPredictions = readyMsg.WantsBallPredictions;
131131
_wantsComms = readyMsg.WantsComms;
132132
_closeBetweenMatches = readyMsg.CloseBetweenMatches;

0 commit comments

Comments
 (0)