Skip to content

Commit

Permalink
Merge pull request #13 from timlenton/master
Browse files Browse the repository at this point in the history
Fixed issue with duplicate nodes being created #10
  • Loading branch information
lukesnowden authored Feb 16, 2017
2 parents e337520 + c73c45a commit 4b62e26
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/LukeSnowden/GoogleShoppingFeed/Node.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ public function attachNodeTo(\SimpleXMLElement $parent)
if ($this->cdata && ! preg_match("#^<!\[CDATA#is", $this->value)) {
$this->value = "<![CDATA[{$this->value}]]>";
}
$parent->addChild($this->name, '', $this->_namespace);
$parent->{$this->name} = $this->value;
$parent->addChild($this->name, $this->value, $this->_namespace);
}
}

0 comments on commit 4b62e26

Please sign in to comment.