[MCR] Add optional $title param to Revision byId methods
[lhc/web/wiklou.git] / includes / Revision.php
index c7c708e..54558a4 100644 (file)
@@ -90,11 +90,12 @@ class Revision implements IDBAccessObject {
         *
         * @param int $id
         * @param int $flags (optional)
+        * @param Title $title (optional)
         * @return Revision|null
         */
-       public static function newFromId( $id, $flags = 0 ) {
-               $rec = self::getRevisionStore()->getRevisionById( $id, $flags );
-               return $rec === null ? null : new Revision( $rec, $flags );
+       public static function newFromId( $id, $flags = 0, Title $title = null ) {
+               $rec = self::getRevisionStore()->getRevisionById( $id, $flags, $title );
+               return $rec === null ? null : new Revision( $rec, $flags, $title );
        }
 
        /**