fix: Cleans up string substring (#1018)

This commit is contained in:
Kamron Batman 2022-05-14 16:56:03 -07:00 • committed by GitHub
parent 87b63b38a5
commit 6ec84b3c01
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 40 additions and 40 deletions

View file

@ -28,7 +28,7 @@ namespace Server.Json
return new ClientVersion(reader.GetString());
}
throw new JsonException($"Value must be a string");
throw new JsonException("Value must be a string");
}
public override void Write(Utf8JsonWriter writer, ClientVersion value, JsonSerializerOptions options) =>

View file

@ -26,7 +26,7 @@ namespace Server.Json
{
JsonTokenType.String => Map.Parse(reader.GetString()),
JsonTokenType.Number => Map.Maps[reader.GetInt32()],
_ => throw new JsonException($"Value must be a number or string")
_ => throw new JsonException("Value must be a number or string")
};
public override void Write(Utf8JsonWriter writer, Map value, JsonSerializerOptions options) =>