fix GetFolderByPath to support root folder path

This commit is contained in:
sbwalker 2023-08-03 17:29:02 -04:00
parent 808354e969
commit 749e11762f

View File

@ -88,6 +88,7 @@ namespace Oqtane.Controllers
public Folder GetByPath(int siteId, string path)
{
var folderPath = WebUtility.UrlDecode(path).Replace("\\", "/");
folderPath = (folderPath == "/") ? "" : folderPath;
if (!folderPath.EndsWith("/") && folderPath != "")
{
folderPath += "/";