Port v7@2aa0dfb2c5 - WIP

This commit is contained in:
Stephan
2018-03-27 10:04:07 +02:00
parent a2a4edb3be
commit 0a4878d2a3
119 changed files with 3016 additions and 1376 deletions

View File

@@ -82,10 +82,19 @@ namespace Umbraco.Web.Trees
private async Task<TreeNode> GetRootForMultipleAppTree(ApplicationTree configTree, FormDataCollection queryStrings)
{
if (configTree == null) throw new ArgumentNullException(nameof(configTree));
var byControllerAttempt = await configTree.TryGetRootNodeFromControllerTree(queryStrings, ControllerContext);
if (byControllerAttempt.Success)
try
{
return byControllerAttempt.Result;
var byControllerAttempt = await configTree.TryGetRootNodeFromControllerTree(queryStrings, ControllerContext);
if (byControllerAttempt.Success)
{
return byControllerAttempt.Result;
}
}
catch (HttpResponseException)
{
//if this occurs its because the user isn't authorized to view that tree, in this case since we are loading multiple trees we
//will just return null so that it's not added to the list.
return null;
}
var legacyAttempt = configTree.TryGetRootNodeFromLegacyTree(queryStrings, Url, configTree.ApplicationAlias);