LinkCache: Make clearBadLink() only clear that link
authorKunal Mehta <legoktm@member.fsf.org>
Tue, 26 Apr 2016 21:36:24 +0000 (14:36 -0700)
committerKunal Mehta <legoktm@member.fsf.org>
Tue, 26 Apr 2016 21:42:47 +0000 (14:42 -0700)
Calling clear() empties all of mBadLinks instead of the one that was
requested.

Change-Id: Iec7f7845704dd5742b5bdf4aff05678194e08054

includes/cache/LinkCache.php

index 8a79bd8..276e818 100644 (file)
@@ -195,8 +195,11 @@ class LinkCache {
                }
        }
 
+       /**
+        * @param string $title prefixed dbkey
+        */
        public function clearBadLink( $title ) {
-               $this->mBadLinks->clear( [ $title ] );
+               $this->mBadLinks->delete( $title );
        }
 
        /**