Files
OurUmbraco/uRepo/RepoStartupHandler.cs
T
Sebastiaan Janssen 5a4c46fb47 Fixes routing conflict
2014-12-07 15:59:47 +01:00

19 lines
592 B
C#

using System.Web.Http;
using System.Web.Routing;
using Umbraco.Core;
namespace uRepo
{
public class AppStart : ApplicationEventHandler
{
protected override void ApplicationInitialized(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
{
RouteTable.Routes.MapHttpRoute(
name: "RepoApi",
routeTemplate: "webapi/{controller}/{id}",
defaults: new { id = RouteParameter.Optional },
constraints: new { controller = "StarterKit" }
);
}
}
}