lib/require.js
function clone(object, deep) {
		if (!object) { return object; }
		var clone = object.prototype
						? Object.create(object.prototype.constructor) : {};

		for(var key in object) {
			if (!object.hasOwnProperty(key)) { continue; }
			clone[key] = deep ? clone(object[key], deep) : object[key];
		}
		return clone;
	}
function clone(object, deep) {
		if (!object) { return object; }
		var clone = object.prototype
						? Object.create(object.prototype.constructor) : {};

		for(var key in object) {
			if (!object.hasOwnProperty(key)) { continue; }
			clone[key] = deep ? clone(object[key], deep) : object[key];
		}
		return clone;
	}
function clone ( object , deep ) { if ( ! object ) { return object ; } var clone = object . prototype ? Object . create ( object . prototype . constructor ) : { } ; for ( var key in object ) { if ( ! object . hasOwnProperty ( key ) ) { continue ; } clone [ key ] = deep ? clone ( object [ key ] , deep ) : object [ key ] ; } return clone ; }
Create a clone of the object specified.  If `deep` is truthy, clone any referenced properties too.
Create a clone of the object specified . If deep is truthy clone any referenced properties too .