From 2b62e6306d310219aaa2f80ea6f40ad5357e36ff Mon Sep 17 00:00:00 2001 From: Per Kops Date: Tue, 17 Dec 2024 10:38:01 +0100 Subject: [PATCH] style: formatting in MessageRequestBuilder --- src/Atc.Rest.Client/Builder/MessageRequestBuilder.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/Atc.Rest.Client/Builder/MessageRequestBuilder.cs b/src/Atc.Rest.Client/Builder/MessageRequestBuilder.cs index 4a327cd..3e0012a 100644 --- a/src/Atc.Rest.Client/Builder/MessageRequestBuilder.cs +++ b/src/Atc.Rest.Client/Builder/MessageRequestBuilder.cs @@ -148,7 +148,7 @@ public IMessageRequestBuilder WithQueryParameter( { var objects = ((IEnumerable)value).Cast().ToArray(); var sb = new StringBuilder(); - for (int i = 0; i < objects.Length; i++) + for (var i = 0; i < objects.Length; i++) { sb.Append(i == 0 ? Uri.EscapeDataString(objects[i].ToString()) @@ -205,9 +205,7 @@ private Uri BuildRequestUri() private static string BuildQueryKeyEqualValue( KeyValuePair pair) - { - return pair.Key.StartsWith("#", StringComparison.Ordinal) + => pair.Key.StartsWith("#", StringComparison.Ordinal) ? $"{pair.Key.Replace("#", string.Empty)}={pair.Value}" : $"{pair.Key}={Uri.EscapeDataString(pair.Value)}"; - } } \ No newline at end of file