Let subclasses specify content model in JsonContent
authorwctaiwan <wctaiwan@gmail.com>
Sat, 10 Jan 2015 05:08:02 +0000 (00:08 -0500)
committerwctaiwan <wctaiwan@gmail.com>
Sat, 10 Jan 2015 05:11:37 +0000 (00:11 -0500)
This is needed for extensions that subclass JsonContent.

Follows up Ifed379ba4674a8289b55
Change-Id: I2f4f9cb343c2ab3ee802b584d3c79d0fafadf9e7

includes/content/JsonContent.php

index ff3b25b..df90f22 100644 (file)
@@ -25,8 +25,8 @@ class JsonContent extends TextContent {
        /**
         * @param string $text JSON
         */
-       public function __construct( $text ) {
-               parent::__construct( $text, CONTENT_MODEL_JSON );
+       public function __construct( $text, $modelId = CONTENT_MODEL_JSON ) {
+               parent::__construct( $text, $modelId );
        }
 
        /**