diff --git a/VectorTemplate.php b/VectorTemplate.php index 2687ddc..96e36ee 100644 --- a/VectorTemplate.php +++ b/VectorTemplate.php @@ -152,7 +152,7 @@ class VectorTemplate extends BaseTemplate {

msg( 'navigation-heading' ) ?>

- renderNavigation( 'PERSONAL' ); ?> + renderNavigation( [ 'PERSONAL' ] ); ?>
renderNavigation( [ 'NAMESPACES', 'VARIANTS' ] ); ?>
@@ -221,7 +221,7 @@ class VectorTemplate extends BaseTemplate { * * @param array $portals */ - protected function renderPortals( $portals ) { + protected function renderPortals( array $portals ) { // Force the rendering of the following portals if ( !isset( $portals['SEARCH'] ) ) { $portals['SEARCH'] = true; @@ -262,7 +262,7 @@ class VectorTemplate extends BaseTemplate { /** * @param string $name - * @param array $content + * @param array|string $content * @param null|string $msg * @param null|string|array $hook */ @@ -316,12 +316,7 @@ class VectorTemplate extends BaseTemplate { * * @param array $elements */ - protected function renderNavigation( $elements ) { - // If only one element was given, wrap it in an array, allowing more - // flexible arguments - if ( !is_array( $elements ) ) { - $elements = [ $elements ]; - } + protected function renderNavigation( array $elements ) { // Render elements foreach ( $elements as $name => $element ) { switch ( $element ) {