diff --git a/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs b/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs index bf41278741..ffbccc2d40 100644 --- a/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs +++ b/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs @@ -53,9 +53,9 @@ namespace Microsoft.AspNet.Mvc.Razor public long Length { get; private set; } /// - /// Gets or sets the last modified for the file at the time of compilation. + /// Gets or sets the last modified for the file at the time of compilation. /// - public DateTime LastModified { get; set; } + public DateTimeOffset LastModified { get; set; } /// /// Gets the file hash, should only be available for pre compiled files. diff --git a/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfo.cs b/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfo.cs index 211970f045..e19113b0a1 100644 --- a/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfo.cs +++ b/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfo.cs @@ -15,7 +15,7 @@ namespace Microsoft.AspNet.Mvc.Razor /// /// Last modified at compilation time. /// - public DateTime LastModified { get; set; } + public DateTimeOffset LastModified { get; set; } /// /// The length of the file in bytes. diff --git a/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfoCollectionGenerator.cs b/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfoCollectionGenerator.cs index 7d3b9e5dad..e7da94f301 100644 --- a/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfoCollectionGenerator.cs +++ b/src/Microsoft.AspNet.Mvc.Razor/Razor/PreCompileViews/RazorFileInfoCollectionGenerator.cs @@ -47,7 +47,7 @@ namespace Microsoft.AspNet.Mvc.Razor protected virtual string GenerateFile([NotNull] RazorFileInfo fileInfo) { return string.Format(FileFormat, - fileInfo.LastModified.ToFileTimeUtc(), + fileInfo.LastModified.ToFileTime(), fileInfo.Length, fileInfo.RelativePath, fileInfo.FullTypeName,