BagOStuff: Don't use $this in a closure
authorKunal Mehta <legoktm@gmail.com>
Fri, 21 Aug 2015 20:32:39 +0000 (13:32 -0700)
committerOri.livneh <ori@wikimedia.org>
Fri, 21 Aug 2015 20:41:11 +0000 (20:41 +0000)
Change-Id: Ib9fb92a70adc2b4d75c30148e17dff6f7765afe1

includes/libs/objectcache/BagOStuff.php

index d72e1a5..2756143 100644 (file)
@@ -294,7 +294,7 @@ abstract class BagOStuff implements LoggerAwareInterface {
                        $latency = .050; // latency skew (err towards keeping lock present)
                        $age = ( microtime( true ) - $lSince + $latency );
                        if ( ( $age + $latency ) >= $expiry ) {
-                               $this->logger->warning( "Lock for $key held too long ($age sec)." );
+                               $that->logger->warning( "Lock for $key held too long ($age sec)." );
                                return; // expired; it's not "safe" to delete the key
                        }
                        $that->unlock( $key );