Fix JSON un-serialisation that forgot to declare elements.
update changes
New method to remove all the attributes of a given element.