their correct locations/namespaces/assemblies and obsoleted all of the old ones and ensure the old webforms files don't exist where the obsoleted ones were. Fixes a security issue with the installer ajax service (used to be p.aspx, now is InstallerRestService.aspx)
50 lines
1.3 KiB
C#
50 lines
1.3 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Collections.Specialized;
|
|
|
|
namespace Umbraco.Web.Install
|
|
{
|
|
internal class InstallerStepCollection : Dictionary<string, InstallerStep>
|
|
{
|
|
public void Add(InstallerStep step){
|
|
step.Index = this.Count;
|
|
this.Add(step.Alias, step);
|
|
}
|
|
|
|
public InstallerStep Get(string key)
|
|
{
|
|
return this.First(item => item.Key == key).Value;
|
|
}
|
|
|
|
public bool StepExists(string key)
|
|
{
|
|
return this.ContainsKey(key);
|
|
}
|
|
|
|
public InstallerStep GotoNextStep(string key)
|
|
{
|
|
var s = this[key];
|
|
foreach(var i in this.Values){
|
|
|
|
// System.Web.HttpContext.Current.Response.Write(i.Index.ToString() + i.Alias);
|
|
|
|
if (i.Index > s.Index && !i.Completed()) {
|
|
// System.Web.HttpContext.Current.Response.Write( "FOUND" + i.Index.ToString() + i.Alias);
|
|
return i;
|
|
}
|
|
}
|
|
|
|
return null;
|
|
}
|
|
|
|
|
|
public InstallerStep FirstAvailableStep()
|
|
{
|
|
return this.First(item => item.Value.Completed() == false ).Value;
|
|
}
|
|
}
|
|
}
|
|
|