support both 404 andf 403 status codes in API response (404 should not log)
This commit is contained in:
@ -65,6 +65,10 @@ namespace Oqtane.Controllers
|
||||
user.SiteId = int.Parse(siteid);
|
||||
user.Roles = GetUserRoles(user.UserId, user.SiteId);
|
||||
}
|
||||
else
|
||||
{
|
||||
HttpContext.Response.StatusCode = (int)HttpStatusCode.NotFound;
|
||||
}
|
||||
return Filter(user);
|
||||
}
|
||||
else
|
||||
@ -88,6 +92,10 @@ namespace Oqtane.Controllers
|
||||
user.SiteId = int.Parse(siteid);
|
||||
user.Roles = GetUserRoles(user.UserId, user.SiteId);
|
||||
}
|
||||
else
|
||||
{
|
||||
HttpContext.Response.StatusCode = (int)HttpStatusCode.NotFound;
|
||||
}
|
||||
return Filter(user);
|
||||
}
|
||||
else
|
||||
|
Reference in New Issue
Block a user