diff --git a/src/xml.coffee b/src/xml.coffee index 745ad02..3ea0c8c 100644 --- a/src/xml.coffee +++ b/src/xml.coffee @@ -126,7 +126,7 @@ class Tag extends EventEmitter attr: (key, value) => if typeof key is 'string' - if not value? + if value is undefined attr = @builder?.query('attr', this, key) # attr is not defined if attr is undefined # attr doesn't have a value when attr is null