some useless calls / unitialized $matches arrays
[lhc/web/wiklou.git] / includes / HistoryBlob.php
index f7fa77a..5875885 100644 (file)
@@ -182,7 +182,7 @@ $wgBlobCache = array();
  * @package MediaWiki
  */
 class HistoryBlobStub {
-       var $mOldId, $mHash;
+       var $mOldId, $mHash, $mRef;
 
        /** @todo document */
        function HistoryBlobStub( $hash = '', $oldid = 0 ) {
@@ -197,6 +197,20 @@ class HistoryBlobStub {
                $this->mOldId = $id;
        }
 
+      /**
+       * Sets the location (old_id) of the referring object
+       */
+      function setReferrer( $id ) {
+              $this->mRef = $id;
+      }
+
+      /**
+       * Gets the location of the referring object
+       */
+      function getReferrer() {
+              return $this->mRef;
+      }
+
        /** @todo document */
        function getText() {
                global $wgBlobCache;
@@ -210,14 +224,14 @@ class HistoryBlobStub {
                        }
                        $flags = explode( ',', $row->old_flags );
                        if( in_array( 'external', $flags ) ) {
-                               $url=$row->old_text;
-                               @list($proto,$path)=explode('://',$url,2);
-                               if ($path=="") {
-                                       wfProfileOut( $fname );
-                                       return false;
-                               }
-                               require_once('ExternalStore.php');
-                               $row->old_text=ExternalStore::fetchFromUrl($url);
+                               $url=$row->old_text;
+                               @list($proto,$path)=explode('://',$url,2);
+                               if ($path=="") {
+                                       wfProfileOut( $fname );
+                                       return false;
+                               }
+                               require_once('ExternalStore.php');
+                               $row->old_text=ExternalStore::fetchFromUrl($url);
 
                        }
                        if( !in_array( 'object', $flags ) ) {