#19752: Don't overwrite an existing etag

Work Item: 19752
This commit is contained in:
Sebastien Ros 2013-08-09 11:54:53 -07:00
parent 6f22578f5b
commit 24d48c72c2

View File

@ -422,7 +422,9 @@ namespace Orchard.OutputCache.Filters {
// an ETag is a string that uniquely identifies a specific version of a component.
// we use the cache item to detect if it's a new one
response.Cache.SetETag(cacheItem.GetHashCode().ToString(CultureInfo.InvariantCulture));
if (response.Headers.Get("ETag") == null) {
response.Cache.SetETag(cacheItem.GetHashCode().ToString(CultureInfo.InvariantCulture));
}
response.Cache.SetOmitVaryStar(true);