We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 112ea2a commit a0772bbCopy full SHA for a0772bb
src/i18n/Concrete/EarlyUrlLocalizer.cs
@@ -189,7 +189,13 @@ protected static void RedirectWithLanguage(
189
context.Response.Status = "302 Moved Temporarily";
190
}
191
context.Response.RedirectLocation = urlNew;
192
- context.Response.End();
+
193
+ // End the request early: no further processing along the pipeline.
194
+ // NB: we did originally use context.Response.End(); here but that causes an
195
+ // unnecessary exception to be thrown (https://support.microsoft.com/en-us/kb/312629) (#195)
196
+ // NB: the line AFTER this line will execute, so best to return immediately here
197
+ // and from caller etc..
198
+ context.ApplicationInstance.CompleteRequest();
199
200
201
/// <summary>
0 commit comments