Modify precompilation to always generate instrumentation
This commit is contained in:
parent
5fa8a91111
commit
2d67f2fc27
|
|
@ -22,6 +22,8 @@ namespace Microsoft.AspNet.Mvc.Razor
|
||||||
Length = info.Length;
|
Length = info.Length;
|
||||||
LastModified = info.LastModified;
|
LastModified = info.LastModified;
|
||||||
Hash = info.Hash;
|
Hash = info.Hash;
|
||||||
|
// Precompiled views are always instrumented.
|
||||||
|
IsInstrumented = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
||||||
|
|
@ -32,6 +32,7 @@ namespace Microsoft.AspNet.Mvc.Razor
|
||||||
{
|
{
|
||||||
_serviceProvider = designTimeServiceProvider;
|
_serviceProvider = designTimeServiceProvider;
|
||||||
_host = host;
|
_host = host;
|
||||||
|
_host.EnableInstrumentation = true;
|
||||||
|
|
||||||
var appEnv = _serviceProvider.GetService<IApplicationEnvironment>();
|
var appEnv = _serviceProvider.GetService<IApplicationEnvironment>();
|
||||||
_fileSystem = optionsAccessor.Options.FileSystem;
|
_fileSystem = optionsAccessor.Options.FileSystem;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue