From c60f308ca569b3e183d45b37ee7e728d5a28547b Mon Sep 17 00:00:00 2001 From: iska Date: Thu, 9 Apr 2015 21:20:04 +0200 Subject: [PATCH] Fix HTML Element copy method Was missing the namespace copy --- HTMLKit/HTMLElement.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/HTMLKit/HTMLElement.m b/HTMLKit/HTMLElement.m index fb0d739..e12b5f7 100644 --- a/HTMLKit/HTMLElement.m +++ b/HTMLKit/HTMLElement.m @@ -42,7 +42,7 @@ { self = [super initWithName:tagName type:HTMLNodeElement]; if (self) { - _tagName = tagName; + _tagName = [tagName copy]; _attributes = [HTMLOrderedDictionary new]; if (attributes != nil) { [_attributes addEntriesFromDictionary:attributes]; @@ -108,6 +108,7 @@ HTMLElement *copy = [super copyWithZone:zone]; copy->_tagName = [_tagName copy]; copy->_attributes = [_attributes copy]; + copy->_htmlNamespace = _htmlNamespace; return copy; }