Merge with 4.11.5
This commit is contained in:
@@ -37,6 +37,14 @@ namespace Umbraco.Core.Configuration
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// used for unit tests
|
||||
/// </summary>
|
||||
internal static void ResetCache()
|
||||
{
|
||||
_reservedUrlsCache = null;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the reserved urls from web.config.
|
||||
/// </summary>
|
||||
/// <value>The reserved urls.</value>
|
||||
@@ -67,7 +75,8 @@ namespace Umbraco.Core.Configuration
|
||||
var staticReservedPaths = "~/app_plugins/,~/install/,";
|
||||
|
||||
//always add the umbraco path to the list
|
||||
if (ConfigurationManager.AppSettings.ContainsKey("umbracoPath"))
|
||||
if (ConfigurationManager.AppSettings.ContainsKey("umbracoPath")
|
||||
&& !ConfigurationManager.AppSettings["umbracoPath"].IsNullOrWhiteSpace())
|
||||
{
|
||||
staticReservedPaths += ConfigurationManager.AppSettings["umbracoPath"].EnsureEndsWith(',');
|
||||
}
|
||||
|
||||
@@ -24,10 +24,12 @@ namespace Umbraco.Tests
|
||||
|
||||
public override void TearDown()
|
||||
{
|
||||
//reset the app config
|
||||
ConfigurationManager.AppSettings.Set("umbracoReservedPaths", "");
|
||||
ConfigurationManager.AppSettings.Set("umbracoReservedUrls", "");
|
||||
Umbraco.Core.Configuration.GlobalSettings.ResetCache();
|
||||
base.TearDown();
|
||||
//reset the app config
|
||||
ConfigurationManager.AppSettings.Set("umbracoReservedPaths", "");
|
||||
ConfigurationManager.AppSettings.Set("umbracoReservedUrls", "");
|
||||
|
||||
}
|
||||
|
||||
[Ignore]
|
||||
|
||||
Reference in New Issue
Block a user