diff --git a/NzbDrone.Api/Frontend/IndexModule.cs b/NzbDrone.Api/Frontend/IndexModule.cs index 2045e2973..46eac2824 100644 --- a/NzbDrone.Api/Frontend/IndexModule.cs +++ b/NzbDrone.Api/Frontend/IndexModule.cs @@ -24,8 +24,7 @@ namespace NzbDrone.Api.Frontend _indexCache = cacheManger.GetCache(typeof(IndexModule)); //Serve anything that doesn't have an extension - Get[@"^(?:.*)$"] = x => Index(); - Get[@"/"] = x => Index(); + Get[@"/(.*)"] = x => Index(); } private object Index() diff --git a/NzbDrone.Api/NzbDrone.Api.csproj b/NzbDrone.Api/NzbDrone.Api.csproj index 56ed08026..7dd87b51a 100644 --- a/NzbDrone.Api/NzbDrone.Api.csproj +++ b/NzbDrone.Api/NzbDrone.Api.csproj @@ -63,13 +63,12 @@ False ..\packages\Microsoft.AspNet.SignalR.Core.1.1.1\lib\net40\Microsoft.AspNet.SignalR.Core.dll - + False - ..\packages\Nancy.0.17.1\lib\net40\Nancy.dll + ..\packages\Nancy.0.16.1\lib\net40\Nancy.dll - - False - ..\packages\Nancy.Authentication.Basic.0.17.1\lib\net40\Nancy.Authentication.Basic.dll + + ..\packages\Nancy.Authentication.Basic.0.16.1\lib\net40\Nancy.Authentication.Basic.dll False diff --git a/NzbDrone.Api/TinyIoCNancyBootstrapper.cs b/NzbDrone.Api/TinyIoCNancyBootstrapper.cs index bd4a05712..8ed1c5795 100644 --- a/NzbDrone.Api/TinyIoCNancyBootstrapper.cs +++ b/NzbDrone.Api/TinyIoCNancyBootstrapper.cs @@ -20,6 +20,15 @@ namespace NzbDrone.Api return this.ApplicationContainer.Resolve(); } + /// + /// Get the moduleKey generator + /// + /// IModuleKeyGenerator instance + protected override sealed IModuleKeyGenerator GetModuleKeyGenerator() + { + return this.ApplicationContainer.Resolve(); + } + /// /// Create a default, unconfigured, container /// @@ -79,8 +88,8 @@ namespace NzbDrone.Api container.Register( typeof(INancyModule), moduleRegistrationType.ModuleType, - moduleRegistrationType.ModuleType.FullName). - AsSingleton(); + moduleRegistrationType.ModuleKey). + AsSingleton(); } } @@ -147,14 +156,14 @@ namespace NzbDrone.Api } /// - /// Retreive a specific module instance from the container + /// Retreive a specific module instance from the container by its key /// /// Container to use - /// Type of the module + /// Module key of the module /// NancyModule instance - protected override sealed INancyModule GetModule(TinyIoCContainer container, Type moduleType) + protected override sealed INancyModule GetModuleByKey(TinyIoCContainer container, string moduleKey) { - return (INancyModule)container.Resolve(moduleType); + return container.Resolve(moduleKey); } /// diff --git a/NzbDrone.Api/packages.config b/NzbDrone.Api/packages.config index 73b126c5b..2d743b79b 100644 --- a/NzbDrone.Api/packages.config +++ b/NzbDrone.Api/packages.config @@ -2,8 +2,8 @@ - - + + diff --git a/NzbDrone.Console/NzbDrone.Console.csproj b/NzbDrone.Console/NzbDrone.Console.csproj index ca36f6d8d..5e6425b74 100644 --- a/NzbDrone.Console/NzbDrone.Console.csproj +++ b/NzbDrone.Console/NzbDrone.Console.csproj @@ -83,14 +83,6 @@ MinimumRecommendedRules.ruleset - - False - ..\packages\Nancy.0.17.1\lib\net40\Nancy.dll - - - False - ..\packages\Nancy.Authentication.Basic.0.17.1\lib\net40\Nancy.Authentication.Basic.dll - False ..\packages\NLog.2.0.1.2\lib\net40\NLog.dll diff --git a/NzbDrone.Console/packages.config b/NzbDrone.Console/packages.config index 1de49248b..d889a47ab 100644 --- a/NzbDrone.Console/packages.config +++ b/NzbDrone.Console/packages.config @@ -1,6 +1,6 @@  - - + + \ No newline at end of file diff --git a/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj b/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj index f83a90b4e..e9f35f536 100644 --- a/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj +++ b/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj @@ -56,13 +56,12 @@ False ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - - False - ..\packages\Nancy.0.17.1\lib\net40\Nancy.dll + + ..\packages\Nancy.0.16.1\lib\net40\Nancy.dll - + False - ..\packages\Nancy.Owin.0.17.1\lib\net40\Nancy.Owin.dll + ..\packages\Nancy.Owin.0.16.1\lib\net40\Nancy.Owin.dll ..\packages\Newtonsoft.Json.5.0.3\lib\net35\Newtonsoft.Json.dll diff --git a/NzbDrone.Integration.Test/packages.config b/NzbDrone.Integration.Test/packages.config index 944360f9b..80db9bbad 100644 --- a/NzbDrone.Integration.Test/packages.config +++ b/NzbDrone.Integration.Test/packages.config @@ -6,8 +6,8 @@ - - + + diff --git a/NzbDrone/NzbDrone.csproj b/NzbDrone/NzbDrone.csproj index 9587c478a..905fff021 100644 --- a/NzbDrone/NzbDrone.csproj +++ b/NzbDrone/NzbDrone.csproj @@ -112,13 +112,12 @@ False ..\packages\Microsoft.Owin.Hosting.1.1.0-beta2\lib\net40\Microsoft.Owin.Hosting.dll - - False - ..\packages\Nancy.0.17.1\lib\net40\Nancy.dll + + ..\packages\Nancy.0.16.1\lib\net40\Nancy.dll - + False - ..\packages\Nancy.Owin.0.17.1\lib\net40\Nancy.Owin.dll + ..\packages\Nancy.Owin.0.16.1\lib\net40\Nancy.Owin.dll False diff --git a/NzbDrone/packages.config b/NzbDrone/packages.config index 2d3615860..4b7086895 100644 --- a/NzbDrone/packages.config +++ b/NzbDrone/packages.config @@ -6,8 +6,8 @@ - - + +