Drop support for building sidebar portal with non-standard format

Bug: T259306
Change-Id: I2015ddc9bfad614e54427d0de4e7874092cfbfe0
This commit is contained in:
Ammar Abdulhamid 2020-08-01 11:20:17 +01:00 committed by Jdlrobson
parent edb3fef5b9
commit 2cd45072b4
1 changed files with 1 additions and 18 deletions

View File

@ -306,26 +306,9 @@ class SkinVector extends SkinMustache {
}
break;
default:
// Historically some portals have been defined using HTML rather than arrays.
// Let's move away from that to a uniform definition.
if ( !is_array( $content ) ) {
$html = $content;
$content = [];
wfDeprecated(
"`content` field in portal $name must be array."
. "Previously it could be a string but this is no longer supported.",
'1.35.0'
);
} else {
$html = false;
}
$portal = $this->getMenuData(
$props[] = $this->getMenuData(
$name, $content, self::MENU_TYPE_PORTAL
);
if ( $html ) {
$portal['html-items'] .= $html;
}
$props[] = $portal;
break;
}
}