From: Aaron Schulz Date: Thu, 5 Nov 2009 08:55:18 +0000 (+0000) Subject: Make newFromID() inherit correctly (ImagePage/CategoryPage...) by using Late Static... X-Git-Tag: 1.31.0-rc.0~38968 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/comptes/ajouter.php?a=commitdiff_plain;h=5836e1ccd53789d53890da54353306688f84c598;p=lhc%2Fweb%2Fwiklou.git Make newFromID() inherit correctly (ImagePage/CategoryPage...) by using Late Static Binding --- diff --git a/includes/Article.php b/includes/Article.php index 105425a3e1..5065280788 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -60,7 +60,7 @@ class Article { */ public static function newFromID( $id ) { $t = Title::newFromID( $id ); - return $t == null ? null : new Article( $t ); + return $t == null ? null : new static( $t ); } /**