From 29b13ab9e4886fcd668b8f5a04e87af65cf89b6e Mon Sep 17 00:00:00 2001 From: Rob Church Date: Sun, 21 Jan 2007 13:47:11 +0000 Subject: [PATCH] Reorder conditions from Werdna's previous commit; shortcut if not a user CSS/JS subpage to avoid the expensive queries --- includes/Title.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/Title.php b/includes/Title.php index aa4727c9b3..62080d87b2 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -1148,7 +1148,7 @@ class Title { return false; } - if ( $doExpensiveQueries && $this->isCascadeProtected() && !$this->isCssJsSubpage() ) { + if ( $doExpensiveQueries && !$this->isCssJsSubpage() && $this->isCascadeProtected() ) { # We /could/ use the protection level on the source page, but it's fairly ugly # as we have to establish a precedence hierarchy for pages included by multiple # cascade-protected pages. So just restrict it to people with 'protect' permission, -- 2.20.1