Skip to content

Commit

Permalink
Update index.js
Browse files Browse the repository at this point in the history
  • Loading branch information
Artoria committed May 6, 2017
1 parent a3baec3 commit c40ba72
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@ var NtApp = function(el){
app.$children.push(sub_app);
namespace = Object.assign(namespace, sub_app.$namespace);
}
var id = el.getAttribute("nt-id");
if(id){ namespace[id] = el; }


if(el.getAttribute){ var id = el.getAttribute("nt-id"); if(id) namespace[id] = el; }
app.$namespace = namespace;
app.$root.$app = app;
}
Expand Down

0 comments on commit c40ba72

Please sign in to comment.