Replace use of &$this
[lhc/web/wiklou.git] / includes / changes / OldChangesList.php
index 8eb06ce..d862ef4 100644 (file)
@@ -50,7 +50,9 @@ class OldChangesList extends ChangesList {
                                $rc->mAttribs['rc_namespace'] . '-' . $rc->mAttribs['rc_title'] );
                }
 
-               if ( !Hooks::run( 'OldChangesListRecentChangesLine', [ &$this, &$html, $rc, &$classes ] ) ) {
+               // Avoid PHP 7.1 warning from passing $this by reference
+               $list = $this;
+               if ( !Hooks::run( 'OldChangesListRecentChangesLine', [ &$list, &$html, $rc, &$classes ] ) ) {
                        return false;
                }