aboutsummaryrefslogtreecommitdiffstats
path: root/includes/resourceloader/VueComponentParser.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/resourceloader/VueComponentParser.php')
-rw-r--r--includes/resourceloader/VueComponentParser.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/includes/resourceloader/VueComponentParser.php b/includes/resourceloader/VueComponentParser.php
index b62ed8cf02a4..7a2aa1befca6 100644
--- a/includes/resourceloader/VueComponentParser.php
+++ b/includes/resourceloader/VueComponentParser.php
@@ -37,7 +37,6 @@ use RemexHtml\TreeBuilder\TreeBuilder;
* @since 1.35
*/
class VueComponentParser {
-
/**
* Parse a Vue single file component, and extract the script, template and style parts.
*
@@ -130,7 +129,7 @@ class VueComponentParser {
* @param array $allowedAttributes Attributes the node is allowed to have
* @throws Exception If the node has an attribute it's not allowed to have
*/
- private function validateAttributes( DOMNode $node, array $allowedAttributes ) {
+ private function validateAttributes( DOMNode $node, array $allowedAttributes ) : void {
if ( $allowedAttributes ) {
foreach ( $node->attributes as $attr ) {
if ( !in_array( $attr->name, $allowedAttributes ) ) {
@@ -152,7 +151,7 @@ class VueComponentParser {
* @param DOMNode $templateNode The <template> node
* @throws Exception If the contents of the <template> node are invalid
*/
- private function validateTemplateTag( DOMNode $templateNode ) {
+ private function validateTemplateTag( DOMNode $templateNode ) : void {
// Verify that the <template> tag only contains one tag, and put it in $rootTemplateNode
// We can't use ->childNodes->length === 1 here because whitespace shows up as text nodes,
// and comments are also allowed.