Restore B/C for ApiOpenSearch json output if warnings are present
authorMarius Hoch <hoo@online.de>
Thu, 30 Apr 2015 00:39:55 +0000 (02:39 +0200)
committerMarius Hoch <hoo@online.de>
Thu, 30 Apr 2015 00:39:55 +0000 (02:39 +0200)
Bug: T97617
Change-Id: Id26f83398c989b7737f52da3f90603ddb533517c

includes/api/ApiOpenSearch.php

index 8c03dce..36026c2 100644 (file)
@@ -212,7 +212,7 @@ class ApiOpenSearch extends ApiBase {
                switch ( $this->getFormat() ) {
                        case 'json':
                                // http://www.opensearch.org/Specifications/OpenSearch/Extensions/Suggestions/1.1
-                               $result->addArrayType( null, 'array' );
+                               $result->addArrayType( null, 'BCarray' );
                                $result->addValue( null, 0, strval( $search ) );
                                $terms = array();
                                $descriptions = array();