Fix search results when $wgDebugToolbar is enabled

When $wgDebugToolbar is enabled, a debuginfo key is always returned from the
API.
Unfortunately that broke the ve.isArray check on the result, breaking the
opensearch calls by the linker.

Change-Id: I907ef6fc2589581cf7333af3968b63b483af65a9
This commit is contained in:
Krenair 2014-01-31 00:37:53 +00:00
parent 4c3da1b017
commit fc56562364

View file

@ -84,7 +84,7 @@ ve.ui.MWLinkTargetInputWidget.prototype.getLookupRequest = function () {
* @param {Mixed} data Response from server
*/
ve.ui.MWLinkTargetInputWidget.prototype.getLookupCacheItemFromData = function ( data ) {
return ve.isArray( data ) && data.length ? data[1] : [];
return data[1] || [];
};
/**