Fix new-reference behavior in diff renderer default tip
authorDan Fuhry <dan@enanocms.org>
Fri, 01 Apr 2016 10:28:01 -0400
changeset 1383198f5207119b
parent 1382 78fbedb876f3
Fix new-reference behavior in diff renderer
includes/diffengine/Renderer.php
     1.1 --- a/includes/diffengine/Renderer.php	Fri Apr 01 10:26:18 2016 -0400
     1.2 +++ b/includes/diffengine/Renderer.php	Fri Apr 01 10:28:01 2016 -0400
     1.3 @@ -30,7 +30,7 @@
     1.4  		/**
     1.5   		* Constructor.
     1.6   		*/
     1.7 -		function Text_Diff_Renderer($params = array())
     1.8 +		function __construct($params = array())
     1.9  		{
    1.10  				foreach ($params as $param => $value) {
    1.11  						$v = '_' . $param;
    1.12 @@ -85,7 +85,7 @@
    1.13  										} else {
    1.14  												if ($ntrail) {
    1.15  														$context = array_slice($edit->orig, 0, $ntrail);
    1.16 -														$block[] = &new Text_Diff_Op_copy($context);
    1.17 +														$block[] = new Text_Diff_Op_copy($context);
    1.18  												}
    1.19  												$output .= $this->_block($x0, $ntrail + $xi - $x0,
    1.20   																								$y0, $ntrail + $yi - $y0,
    1.21 @@ -101,7 +101,7 @@
    1.22  										$y0 = $yi - count($context);
    1.23  										$block = array();
    1.24  										if ($context) {
    1.25 -												$block[] = &new Text_Diff_Op_copy($context);
    1.26 +												$block[] = new Text_Diff_Op_copy($context);
    1.27  										}
    1.28  								}
    1.29  								$block[] = $edit;