Skip to content

Commit 124b627

Browse files
committed
Re-fixing oauth parameter name encoding
1 parent 6dd80ef commit 124b627

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

RestSharp/Authenticators/OAuth/OAuthTools.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ public static WebParameterCollection SortParametersExcludingSignature(WebParamet
141141
var exclusions = copy.Where(n => n.Name.EqualsIgnoreCase("oauth_signature"));
142142

143143
copy.RemoveAll(exclusions);
144-
copy.ForEach(p => p.Value = UrlEncodeStrict(p.Value));
144+
copy.ForEach(p => { p.Name = UrlEncodeStrict(p.Name); p.Value = UrlEncodeStrict(p.Value); });
145145
copy.Sort(
146146
(x, y) =>
147147
string.CompareOrdinal(x.Name, y.Name) != 0

RestSharp/Authenticators/OAuth/WebPair.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@ public WebPair(string name, string value)
99
}
1010

1111
public string Value { get; set; }
12-
public string Name { get; private set; }
12+
public string Name { get; set; }
1313
}
1414
}

0 commit comments

Comments
 (0)