From e7c84507ab3856e913e427bdf8f65ffeaad7d8aa Mon Sep 17 00:00:00 2001 From: Vadim Kiryukhin Date: Sun, 18 Mar 2012 22:45:22 -0700 Subject: [PATCH] fixed bug "namespace sometimes is considered as a tag name" --- vkbeautify.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vkbeautify.js b/vkbeautify.js index 44092a6..7390ad0 100644 --- a/vkbeautify.js +++ b/vkbeautify.js @@ -74,7 +74,7 @@ vkbeautify.prototype.xml = function(text) { } else // // if( /^<\w/.exec(ar[ix-1]) && /^<\/\w/.exec(ar[ix]) && - /^<\w+/.exec(ar[ix-1]) == /^<\/\w+/.exec(ar[ix])[0].replace('/','')) { + /^<[\w:\-\.\,]+/.exec(ar[ix-1]) == /^<\/[\w:\-\.\,]+/.exec(ar[ix])[0].replace('/','')) { str += ar[ix]; if(!inComment) deep--; } else