Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Aaron 20 posts 180 karma points
    Feb 18, 2019 @ 15:55
    Aaron
    0

    Hi,

    I am having real problems when trying to enable cors on Umbraco if Plumber is installed.

    I followed the comment here: https://our.umbraco.com/forum/umbraco-7/using-umbraco-7/63841-Web-API-2-and-cross-origin-resource-sharing-CORS#comment-226426

    The error which is thrown is:

    <Error><Message>An error has occurred.</Message><ExceptionMessage>The object has not yet been initialized. Ensure that HttpConfiguration.EnsureInitialized() is called in the application's startup code after all other initialization code.</ExceptionMessage><ExceptionType>System.InvalidOperationException</ExceptionType><StackTrace>   at System.Web.Http.Routing.RouteCollectionRoute.get_SubRoutes()
       at System.Web.Http.Routing.RouteCollectionRoute.GetRouteData(String virtualPathRoot, HttpRequestMessage request)
       at System.Web.Http.WebHost.Routing.HttpWebRoute.GetRouteData(HttpContextBase httpContext)</StackTrace></Error>
    

    This is on umbraco 7.13.2 with WebApi 5.2.6

    I have tried using all the application start handlers instead of overriding with the above comments code, with the same outcome.

    Any help would be appreciated!

Please Sign in or register to post replies

Write your reply to:

Draft