lib/utils.js
function extendObject(obj) {
        for (var i = 1, len = arguments.length; i < len; i++) {
            for (var p in arguments[i]) {
                if (arguments[i].hasOwnProperty(p)) {
                    obj[p] = arguments[i][p];
                }
            }
        }

        return obj;
    }
function extendObject(obj) {
        for (var i = 1, len = arguments.length; i < len; i++) {
            for (var p in arguments[i]) {
                if (arguments[i].hasOwnProperty(p)) {
                    obj[p] = arguments[i][p];
                }
            }
        }

        return obj;
    }
function extendObject ( obj ) { for ( var i = 1 , len = arguments . length ; i < len ; i ++ ) { for ( var p in arguments [ i ] ) { if ( arguments [ i ] . hasOwnProperty ( p ) ) { obj [ p ] = arguments [ i ] [ p ] ; } } } return obj ; }
/*
This function extends the given object with any number of
other objects (parameters two, three, etc.), and returns it.
/ * This function extends the given object with any number of other objects ( parameters two three etc . ) and returns it .