Further optimise / clean-up Bootstrap core.

This commit is contained in:
Jürg Lehni 2011-03-05 20:07:58 +00:00
parent 79d5a46cab
commit 736b79fa29

8
lib/bootstrap.js vendored
View file

@ -18,14 +18,16 @@
*/
var Base = this.Base = new function() {
var fix = !this.__proto__,
hidden = /^(statics|generics|preserve|beans|enumerable|prototype|__proto__|toString|valueOf)$/,
proto = Object.prototype,
has = fix
? function(name) {
return name != '__proto__' && this.hasOwnProperty(name);
}
: {}.hasOwnProperty,
hidden = /^(statics|generics|preserve|beans|enumerable|prototype|__proto__|toString|valueOf)$/,
: proto.hasOwnProperty,
toString = proto.toString,
isArray = Array.isArray = Array.isArray || function(obj) {
return Object.prototype.toString.call(obj) === '[object Array]';
return toString.call(obj) === '[object Array]';
},
proto = Array.prototype,
forEach = proto.forEach = proto.forEach || function(iter, bind) {