Array.prototype.keyExists = function(key) {
for (var i in this) {
if (i==key) return true;
}
return false;
};
Hopefully this is self explanatory as I'm being lazy and I'm not in the mood to write out detailed examples of how to use it.
Array.prototype.keyExists = function(key) {
for (var i in this) {
if (i==key) return true;
}
return false;
};
No comments:
Post a Comment