diff options
| author | Claus Vium <clausvium@gmail.com> | 2019-02-25 23:34:32 +0100 |
|---|---|---|
| committer | Claus Vium <clausvium@gmail.com> | 2019-02-26 22:11:21 +0100 |
| commit | 852460b99155e015ed5f1d7ad2fab0281bfdfbec (patch) | |
| tree | bedbe59bfef06ce6acf8c774622545c0dc7549a4 /MediaBrowser.Model/Services/QueryParamCollection.cs | |
| parent | 33b67a357fe73103f046b822d7cc66fc5318a9ef (diff) | |
kestrel init
Diffstat (limited to 'MediaBrowser.Model/Services/QueryParamCollection.cs')
| -rw-r--r-- | MediaBrowser.Model/Services/QueryParamCollection.cs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/MediaBrowser.Model/Services/QueryParamCollection.cs b/MediaBrowser.Model/Services/QueryParamCollection.cs index 0e0ebf848..09806ed9c 100644 --- a/MediaBrowser.Model/Services/QueryParamCollection.cs +++ b/MediaBrowser.Model/Services/QueryParamCollection.cs @@ -4,6 +4,7 @@ using System.Collections.Specialized; using System.Linq; using System.Net; using MediaBrowser.Model.Dto; +using Microsoft.AspNetCore.Http; namespace MediaBrowser.Model.Services { @@ -23,6 +24,14 @@ namespace MediaBrowser.Model.Services } } + public QueryParamCollection(Microsoft.AspNetCore.Http.IHeaderDictionary headers) + { + foreach (var pair in headers) + { + Add(pair.Key, pair.Value); + } + } + // TODO remove this shit public QueryParamCollection(WebHeaderCollection webHeaderCollection) { @@ -47,6 +56,14 @@ namespace MediaBrowser.Model.Services } } + public QueryParamCollection(IQueryCollection queryCollection) + { + foreach (var pair in queryCollection) + { + Add(pair.Key, pair.Value); + } + } + private static StringComparison GetStringComparison() { return StringComparison.OrdinalIgnoreCase; |
