Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(642)

Unified Diff: content/browser/webui/shared_resources_data_source.cc

Issue 2774263002: Specify AllowCaching = false for dynamically-generated contents (Closed)
Patch Set: typo Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/webui/shared_resources_data_source.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/webui/shared_resources_data_source.cc
diff --git a/content/browser/webui/shared_resources_data_source.cc b/content/browser/webui/shared_resources_data_source.cc
index 693fda185408d5e806538f472ab1e6c6bf0f01fa..9442629c653776d4ace44a87559ff489efe4c9e6 100644
--- a/content/browser/webui/shared_resources_data_source.cc
+++ b/content/browser/webui/shared_resources_data_source.cc
@@ -109,6 +109,12 @@ void SharedResourcesDataSource::StartDataRequest(
callback.Run(bytes.get());
}
+bool SharedResourcesDataSource::AllowCaching() const {
+ // Should not be cached to reflect dynamically-generated contents that may
+ // depend on the current locale.
+ return false;
+}
+
std::string SharedResourcesDataSource::GetMimeType(
const std::string& path) const {
if (path.empty())
« no previous file with comments | « content/browser/webui/shared_resources_data_source.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698