Skip to content

Commit 94931d5

Browse files
committed
Fixed a error in the JavaScriptEngineSwitcher.Sample.AspNetCore1Full.Mvc1 project
1 parent 4827442 commit 94931d5

File tree

1 file changed

+6
-0
lines changed
  • samples/JavaScriptEngineSwitcher.Sample.AspNetCore1Full.Mvc1

1 file changed

+6
-0
lines changed

samples/JavaScriptEngineSwitcher.Sample.AspNetCore1Full.Mvc1/Startup.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
using Microsoft.AspNetCore.Builder;
22
using Microsoft.AspNetCore.Hosting;
33
using Microsoft.AspNetCore.Mvc;
4+
using Microsoft.AspNetCore.Mvc.ApplicationParts;
45
using Microsoft.Extensions.Configuration;
56
using Microsoft.Extensions.DependencyInjection;
67
using Microsoft.Extensions.Logging;
@@ -69,6 +70,11 @@ public void ConfigureServices(IServiceCollection services)
6970
;
7071

7172
// Add framework services.
73+
var manager = new ApplicationPartManager();
74+
manager.ApplicationParts.Add(new AssemblyPart(typeof(Startup).Assembly));
75+
76+
services.AddSingleton(manager);
77+
7278
services.AddMvc(options =>
7379
{
7480
options.CacheProfiles.Add("CacheCompressedContent5Minutes",

0 commit comments

Comments
 (0)