Update psr/log to v1.0.2
[lhc/web/wiklou.git] / includes / Block.php
index 20cb614..9d3a2f9 100644 (file)
@@ -765,8 +765,10 @@ class Block {
                        return false;
                }
 
+               // Avoid PHP 7.1 warning of passing $this by reference
+               $block = $this;
                # Allow hooks to cancel the autoblock.
-               if ( !Hooks::run( 'AbortAutoblock', [ $autoblockIP, &$this ] ) ) {
+               if ( !Hooks::run( 'AbortAutoblock', [ $autoblockIP, &$block ] ) ) {
                        wfDebug( "Autoblock aborted by hook.\n" );
                        return false;
                }