(function(){
Array.prototype.isItemRepeat = function(){
var nary = this.sort();
for(var i=0;i<this.length;i++){
if (nary[i]==nary[i+1]){
return true;
}
}
return false;
}
Array.prototype.isItemRepeat2 = function(){
var hash = {};
for(var i in this) {
if(hash[this[i]]) {
return true;
}
hash[this[i]] = true;
}
return false;
}
Array.prototype.toUniquePropertyArray = function(properyName){
var arr = [];
JSON.parse(JSON.stringify(this, [properyName])).reduce(function(html, current){
arr.push(current[properyName])
},null);
return arr;
}
}());