Fixed the cleaning method to support namespaced elements. Thanks to einaros for the...