fix #5988 - add inline script support to static rendering
This commit is contained in:
@@ -24,7 +24,7 @@ namespace Oqtane.Models
|
||||
get => _url;
|
||||
set
|
||||
{
|
||||
_url = (value.Contains("://")) ? value : (!value.StartsWith("/") && !value.StartsWith("~") ? "/" : "") + value;
|
||||
_url = (string.IsNullOrEmpty(value) || value.Contains("://")) ? value : (!value.StartsWith("/") && !value.StartsWith("~") ? "/" : "") + value;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -501,11 +501,11 @@ namespace Oqtane.Shared
|
||||
|
||||
public static string GetUrlPath(string url)
|
||||
{
|
||||
if (url.Contains("?"))
|
||||
if (!string.IsNullOrEmpty(url) && url.Contains("?"))
|
||||
{
|
||||
url = url.Substring(0, url.IndexOf("?"));
|
||||
}
|
||||
return url;
|
||||
return url ?? "";
|
||||
}
|
||||
|
||||
public static string LogMessage(object @class, string message)
|
||||
|
||||
Reference in New Issue
Block a user