mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-03-31 22:23:05 +02:00
When posting new mapping, use DateParseHandling.None (#348)
* . * OfType + test * remove line
This commit is contained in:
@@ -40,7 +40,7 @@ namespace WireMock.RequestBuilders
|
||||
/// <returns>A List{T}</returns>
|
||||
public IList<T> GetRequestMessageMatchers<T>() where T : IRequestMatcher
|
||||
{
|
||||
return new ReadOnlyCollection<T>(_requestMatchers.Where(rm => rm is T).Cast<T>().ToList());
|
||||
return new ReadOnlyCollection<T>(_requestMatchers.OfType<T>().ToList());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -50,7 +50,7 @@ namespace WireMock.RequestBuilders
|
||||
/// <returns>A RequestMatcher</returns>
|
||||
public T GetRequestMessageMatcher<T>() where T : IRequestMatcher
|
||||
{
|
||||
return _requestMatchers.Where(rm => rm is T).Cast<T>().FirstOrDefault();
|
||||
return _requestMatchers.OfType<T>().FirstOrDefault();
|
||||
}
|
||||
|
||||
/// <inheritdoc cref="IClientIPRequestBuilder.WithClientIP(IStringMatcher[])"/>
|
||||
|
||||
Reference in New Issue
Block a user