Don't add version string if it already exists

I reuse a Wappalyzer object and this keeps adding version strings, even when they are already in the array
main
Janpot 12 years ago
parent 33a9b3a2d5
commit 4fae112cd9

@ -95,7 +95,7 @@ var wappalyzer = (function() {
version = version.replace('\\' + i, match ? match : ''); version = version.replace('\\' + i, match ? match : '');
}); });
if ( version ) { if ( version && this.versions.indexOf(version) < 0 ) {
this.versions.push(version); this.versions.push(version);
} }