lib/utils.js
function options(defaults, opts) {
  for (var p in opts) {
    if (opts[p] && opts[p].constructor && opts[p].constructor === Object) {
      defaults[p] = defaults[p] || {};
      options(defaults[p], opts[p]);
    } else {
      defaults[p] = opts[p];
    }
  }
  return defaults;
}
function options(defaults, opts) {
  for (var p in opts) {
    if (opts[p] && opts[p].constructor && opts[p].constructor === Object) {
      defaults[p] = defaults[p] || {};
      options(defaults[p], opts[p]);
    } else {
      defaults[p] = opts[p];
    }
  }
  return defaults;
}
function options ( defaults , opts ) { for ( var p in opts ) { if ( opts [ p ] && opts [ p ] . constructor && opts [ p ] . constructor === Object ) { defaults [ p ] = defaults [ p ] || { } ; options ( defaults [ p ] , opts [ p ] ) ; } else { defaults [ p ] = opts [ p ] ; } } return defaults ; }
Copies and merges options with defaults.

@param {Object} defaults
@param {Object} supplied options
@return {Object} new (merged) object
Copies and merges options with defaults .