Fix build breaks
This commit is contained in:
parent
bc2bce8bd6
commit
76dceaef76
|
|
@ -16,7 +16,7 @@ namespace Microsoft.AspNet.Mvc.Razor.Compilation
|
|||
/// <param name="optionsAccessor">An accessor to the <see cref="RazorViewEngineOptions"/>.</param>
|
||||
public DefaultCompilerCacheProvider(IOptions<RazorViewEngineOptions> mvcViewOptions)
|
||||
{
|
||||
var fileProvider = mvcViewOptions.Options.FileProvider;
|
||||
var fileProvider = mvcViewOptions.Value.FileProvider;
|
||||
Cache = new CompilerCache(fileProvider);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ namespace Microsoft.AspNet.Mvc.Razor.Compilation
|
|||
IEnumerable<Assembly> assemblies)
|
||||
{
|
||||
_loadContextAccessor = loadContextAccessor;
|
||||
_fileProvider = mvcViewOptions.Options.FileProvider;
|
||||
_fileProvider = mvcViewOptions.Value.FileProvider;
|
||||
_createCache = CreateCache;
|
||||
_assemblies = assemblies.ToArray();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ namespace Microsoft.Framework.DependencyInjection
|
|||
services.TryAdd(ServiceDescriptor.Singleton<IChunkTreeCache>(serviceProvider =>
|
||||
{
|
||||
var cachedFileProvider = serviceProvider.GetRequiredService<IOptions<RazorViewEngineOptions>>();
|
||||
return new DefaultChunkTreeCache(cachedFileProvider.Options.FileProvider);
|
||||
return new DefaultChunkTreeCache(cachedFileProvider.Value.FileProvider);
|
||||
}));
|
||||
|
||||
// Caches compilation artifacts across the lifetime of the application.
|
||||
|
|
|
|||
Loading…
Reference in New Issue