lib/requester/core.js
function (headers, headerKey, defaultValue) {
        var headerName = _.findKey(headers, function (value, key) {
            return key.toLowerCase() === headerKey.toLowerCase();
        });

        if (!headerName) {
            headers[headerKey] = defaultValue;
        }
    }
function (headers, headerKey, defaultValue) {
        var headerName = _.findKey(headers, function (value, key) {
            return key.toLowerCase() === headerKey.toLowerCase();
        });

        if (!headerName) {
            headers[headerKey] = defaultValue;
        }
    }
function ( headers , headerKey , defaultValue ) { var headerName = _ . findKey ( headers , function ( value , key ) { return key . toLowerCase ( ) === headerKey . toLowerCase ( ) ; } ) ; if ( ! headerName ) { headers [ headerKey ] = defaultValue ; } }
Checks if a header already exists. If it does not, sets the value to whatever is passed as
`defaultValue`

@param {object} headers
@param {String} headerKey
@param {String} defaultValue
Checks if a header already exists . If it does not sets the value to whatever is passed as defaultValue