From 2b3501dc5e1a6b014472edde8931a710d0df4e18 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Wed, 2 Apr 2008 06:30:31 +0000 Subject: [PATCH] Fake log_id if needed --- includes/SpecialLog.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/includes/SpecialLog.php b/includes/SpecialLog.php index 901b86aea6..338aae09e7 100644 --- a/includes/SpecialLog.php +++ b/includes/SpecialLog.php @@ -162,10 +162,13 @@ class LogPager extends ReverseChronologicalPager { function getQueryInfo() { $this->mConds[] = 'user_id = log_user'; + # Hack this until live + global $wgAllowLogDeletion; + $log_id = $wgAllowLogDeletion ? 'log_id' : '0 AS log_id'; return array( 'tables' => array( 'logging', 'user' ), 'fields' => array( 'log_type', 'log_action', 'log_user', 'log_namespace', 'log_title', - 'log_params', 'log_comment', 'log_id', 'log_deleted', 'log_timestamp', 'user_name' ), + 'log_params', 'log_comment', $log_id, 'log_deleted', 'log_timestamp', 'user_name' ), 'conds' => $this->mConds, 'options' => array() ); -- 2.20.1