code: function className(object, defaultName) {
  	if (object == null) {
  		return defaultName;
  	}
  
  	var result = '';
  	if (typeof object === 'function') {
  		if (object.name) {
  			result = object.name;
  		} else {
  			var match = object.toString().match(nameFromToStringRegex);
  			if (match !== null) {
  				result = match[1];
  			}
  		}
  	} else if (typeof object.constructor === 'function') {
  		result = className(object.constructor, defaultName);
  	}
  
  	return result || defaultName;
  }
docs: Gets the classname of an object or function if it can.  Otherwise returns the provided default. Getting the name
  of a function is not a standard feature, so while this will work in many cases, it should not be relied upon
  except for informational messages (e.g. logging and Error messages).
  @private