Skip to content
This repository has been archived by the owner on Jun 16, 2022. It is now read-only.

[BugFix] AdvancedView is throwing an exception when having a single domain configured in umbraco. #86

Merged
merged 1 commit into from
Jul 6, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions UI/UserControls/AdvancedView.ascx.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,12 @@ public void LoadView()
pnlRootNode.Visible = false;
}

ddlRootNode.SelectedValue = UrlTrackerModel.RedirectRootNodeId.ToString();
if (!string.IsNullOrEmpty(UrlTrackerModel.OldRegex) && string.IsNullOrEmpty(UrlTrackerModel.OldUrl))
if (ddlRootNode.Items.Count > 1)
{
ddlRootNode.SelectedValue = UrlTrackerModel.RedirectRootNodeId.ToString();
}

if (!string.IsNullOrEmpty(UrlTrackerModel.OldRegex) && string.IsNullOrEmpty(UrlTrackerModel.OldUrl))
{
tbOldRegex.Text = UrlTrackerModel.OldRegex;
}
Expand Down