Call to a member function getCommonMetaArray() on a non-object at
authorReedy <reedy@wikimedia.org>
Tue, 7 Jan 2014 20:04:14 +0000 (20:04 +0000)
committerSiebrand <siebrand@wikimedia.org>
Wed, 8 Jan 2014 10:28:43 +0000 (10:28 +0000)
File.php on line 586

Bug: 59785
Change-Id: I7163f3fd122922a28519b7cb1d3d4cd4b81165ee

includes/filerepo/file/File.php

index dc35016..c9e435e 100644 (file)
@@ -583,6 +583,9 @@ abstract class File {
        public function getCommonMetaArray() {
                $handler = $this->getHandler();
 
+               if ( !$handler ) {
+                       return false;
+               }
                return $handler->getCommonMetaArray( $this );
        }