PortableInfobox/services/Parser/Nodes/NodeData.php
idradm e2a0a2273e Merge branch 'dev' into DAT-2875-refactor
# Conflicts:
#	extensions/wikia/PortableInfobox/services/Parser/Nodes/Node.php
#	extensions/wikia/PortableInfobox/services/Parser/Nodes/NodeData.php
#	extensions/wikia/PortableInfobox/tests/ParserNodesTest.php
2015-06-11 19:12:55 +02:00

17 lines
345 B
PHP

<?php
namespace Wikia\PortableInfobox\Parser\Nodes;
class NodeData extends Node {
public function getData() {
if ( !isset( $this->data ) ) {
$this->data = [
'label' => $this->getValueWithData( $this->xmlNode->{self::LABEL_TAG_NAME} ),
'value' => $this->getValueWithDefault( $this->xmlNode )
];
}
return $this->data;
}
}