add auxiliar httpresponse.Redirect(string url, [HttpStatusCode redirStatusCode = HttpStatusCode.Redirect])

This commit is contained in:
UbitUmarov
2021-12-20 11:07:26 +00:00
parent 112a86b9e0
commit 3f584dbf12
10 changed files with 58 additions and 23 deletions

View File

@@ -136,9 +136,8 @@ namespace OpenSim.Capabilities.Handlers
if(!String.IsNullOrEmpty(m_RedirectURL))
{
string textureUrl = m_RedirectURL + "?texture_id=" + textureID.ToString();
httpResponse.Redirect(textureUrl, HttpStatusCode.Moved);
m_log.Debug("[GETTEXTURE]: Redirecting texture request to " + textureUrl);
httpResponse.StatusCode = (int)HttpStatusCode.Moved;
httpResponse.AddHeader("Location:", textureUrl);
return true;
}