add some defensive logic in file handler
This commit is contained in:
@@ -48,7 +48,7 @@ namespace Oqtane.Pages
|
|||||||
|
|
||||||
public IActionResult OnGet(string path)
|
public IActionResult OnGet(string path)
|
||||||
{
|
{
|
||||||
if (string.IsNullOrWhiteSpace(path))
|
if (string.IsNullOrWhiteSpace(path) || _alias == null)
|
||||||
{
|
{
|
||||||
HttpContext.Response.StatusCode = (int)HttpStatusCode.Forbidden;
|
HttpContext.Response.StatusCode = (int)HttpStatusCode.Forbidden;
|
||||||
return BrokenFile();
|
return BrokenFile();
|
||||||
|
|||||||
Reference in New Issue
Block a user