From 794c5749696c9fa2595ed3a1d7c836a0d984e11c Mon Sep 17 00:00:00 2001 From: Meik Sievertsen Date: Sun, 22 Feb 2009 15:29:18 +0000 Subject: remove global and change $user-> to phpbb::$user-> git-svn-id: file:///svn/phpbb/trunk@9334 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/diff/diff.php | 8 +++----- phpBB/includes/diff/renderer.php | 14 ++++++-------- 2 files changed, 9 insertions(+), 13 deletions(-) (limited to 'phpBB/includes/diff') diff --git a/phpBB/includes/diff/diff.php b/phpBB/includes/diff/diff.php index 0837ac90d1..674a3b58b4 100644 --- a/phpBB/includes/diff/diff.php +++ b/phpBB/includes/diff/diff.php @@ -439,8 +439,6 @@ class diff3 extends diff */ function merged_output($label1 = 'CURRENT_FILE', $label2 = 'NEW_FILE', $label_sep = 'DIFF_SEP_EXPLAIN', $get_conflicts = false, $merge_new = false) { - global $user; - if ($get_conflicts) { foreach ($this->_edits as $edit) @@ -454,9 +452,9 @@ class diff3 extends diff return $this->_conflicting_blocks; } - $label1 = (!empty($user->lang[$label1])) ? $user->lang[$label1] : $label1; - $label2 = (!empty($user->lang[$label2])) ? $user->lang[$label2] : $label2; - $label_sep = (!empty($user->lang[$label_sep])) ? $user->lang[$label_sep] : $label_sep; + $label1 = (!empty(phpbb::$user->lang[$label1])) ? phpbb::$user->lang[$label1] : $label1; + $label2 = (!empty(phpbb::$user->lang[$label2])) ? phpbb::$user->lang[$label2] : $label2; + $label_sep = (!empty(phpbb::$user->lang[$label_sep])) ? phpbb::$user->lang[$label_sep] : $label_sep; $lines = array(); diff --git a/phpBB/includes/diff/renderer.php b/phpBB/includes/diff/renderer.php index 7f7a3366b1..8194b63da6 100644 --- a/phpBB/includes/diff/renderer.php +++ b/phpBB/includes/diff/renderer.php @@ -598,15 +598,13 @@ class diff_renderer_side_by_side extends diff_renderer */ function get_diff_content($diff) { - global $user; - $output = ''; $output .= ' '; @@ -616,14 +614,14 @@ class diff_renderer_side_by_side extends diff_renderer // Is the diff empty? if (!sizeof($this->lines)) { - $output .= ''; + $output .= ''; } else { // Iterate through every header block of changes foreach ($this->lines as $header) { - $output .= ''; + $output .= ''; // Each header block consists of a number of changes (add, remove, change). $current_context = ''; -- cgit v1.2.1
-   ' . $user->lang['LINE_UNMODIFIED'] . ' -   ' . $user->lang['LINE_ADDED'] . ' -   ' . $user->lang['LINE_MODIFIED'] . ' -   ' . $user->lang['LINE_REMOVED'] . ' +   ' . phpbb::$user->lang['LINE_UNMODIFIED'] . ' +   ' . phpbb::$user->lang['LINE_ADDED'] . ' +   ' . phpbb::$user->lang['LINE_MODIFIED'] . ' +   ' . phpbb::$user->lang['LINE_REMOVED'] . '
' . $user->lang['NO_VISIBLE_CHANGES'] . '
' . phpbb::$user->lang['NO_VISIBLE_CHANGES'] . '
' . $user->lang['LINE'] . ' ' . $header['oldline'] . '' . $user->lang['LINE'] . ' ' . $header['newline'] . '
' . phpbb::$user->lang['LINE'] . ' ' . $header['oldline'] . '' . phpbb::$user->lang['LINE'] . ' ' . $header['newline'] . '