Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Griddly.Mvc/NetFramework/GriddlySettingsResult.cs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ public override object GetService(Type serviceType)

class EmptyHttpRequest : HttpRequestBase
{
public EmptyHttpRequest (HttpRequestBase originalRequest)
public EmptyHttpRequest(HttpRequestBase originalRequest)
{
_originalRequest = originalRequest;
}
Expand Down Expand Up @@ -172,6 +172,7 @@ public EmptyHttpRequest (HttpRequestBase originalRequest)
public override string ContentType { get { return _originalRequest.ContentType; } set { } }
public override System.Text.Encoding ContentEncoding { get { return _originalRequest.ContentEncoding; } set { } }
public override RequestContext RequestContext { get; set; }
public override string this[string key] => QueryString[key] ?? Form[key] ?? Cookies[key]?.Value ?? ServerVariables[key];

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or you could also

Suggested change
public override string this[string key] => QueryString[key] ?? Form[key] ?? Cookies[key]?.Value ?? ServerVariables[key];
public override string this[string key] => _originalRequest[key];

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but I am not sure if/what EMPTYHttpRequest should return in the first place... I just don't want it to throw

}

class EmptyHttpResponse : HttpResponseBase
Expand Down