Permalink
Browse files

Builder::remove

  • Loading branch information...
1 parent 83fd06f commit c240ca9980a51b9be811ab1351088d6ae0c40d3e @dodo committed Apr 28, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/xml.coffee
View
@@ -260,7 +260,7 @@ class Tag extends EventEmitter
remove: (opts = {}) =>
@closed = 'removed' unless @closed or opts.soft
@emit 'remove', this, opts
- @builder = null
+ @builder = null unless this is @builder
@parent = null
@emit 'removed', opts.soft # internal
@removeAllListeners() unless opts.soft
@@ -292,6 +292,7 @@ class Builder extends EventEmitter
show: Tag::show
hide: Tag::hide
+ remove: Tag::remove
toString: ->
"[object AsyncXMLBuilder]"

0 comments on commit c240ca9

Please sign in to comment.