Skip to content

Commit

Permalink
fix attributeless element exception
Browse files Browse the repository at this point in the history
  • Loading branch information
developit committed Sep 14, 2016
1 parent c1158a4 commit 7001351
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/markup-to-vdom.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function visitor(node) {
map = visitor.map;
if (map && map.hasOwnProperty(name)){
node.nodeName = map[name];
node.attributes = Object.keys(node.attributes).reduce((attrs,attrName)=>{
node.attributes = Object.keys(node.attributes || {}).reduce((attrs,attrName)=>{
attrs[toCamelCase(attrName)] = node.attributes[attrName];
return attrs;
},{});
Expand Down

0 comments on commit 7001351

Please sign in to comment.