From fb3b6d13b8e9f594b248b0485af0c9429d3c7ee1 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Thu, 17 Jul 2008 21:10:39 +0000 Subject: - Patch #231190 by eli, mfb: page cache didn't work with HEAD requests. --- includes/common.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'includes/common.inc') diff --git a/includes/common.inc b/includes/common.inc index 7263d0a5b..ee604fb9e 100644 --- a/includes/common.inc +++ b/includes/common.inc @@ -2490,7 +2490,7 @@ function _drupal_bootstrap_full() { function page_set_cache() { global $user, $base_root; - if (!$user->uid && $_SERVER['REQUEST_METHOD'] == 'GET' && count(drupal_get_messages(NULL, FALSE)) == 0) { + if (!$user->uid && ($_SERVER['REQUEST_METHOD'] == 'GET' || $_SERVER['REQUEST_METHOD'] == 'HEAD') && count(drupal_get_messages(NULL, FALSE)) == 0) { // This will fail in some cases, see page_get_cache() for the explanation. if ($data = ob_get_contents()) { $cache = TRUE; -- cgit v1.2.3