lib/response.js
function(field, val){
            if (2 == arguments.length) {
                if (Array.isArray(val)) val = val.map(String);
                else val = String(val);
                this.res.setHeader(field, val);
            } else {
                for (var key in field) {
                    this.set(key, field[key]);
                }
            }
        }
function(field, val){
            if (2 == arguments.length) {
                if (Array.isArray(val)) val = val.map(String);
                else val = String(val);
                this.res.setHeader(field, val);
            } else {
                for (var key in field) {
                    this.set(key, field[key]);
                }
            }
        }
function ( field , val ) { if ( 2 == arguments . length ) { if ( Array . isArray ( val ) ) val = val . map ( String ) ; else val = String ( val ) ; this . res . setHeader ( field , val ) ; } else { for ( var key in field ) { this . set ( key , field [ key ] ) ; } } }
Set header `field` to `val`, or pass
an object of header fields.

Examples:

this.set('Foo', ['bar', 'baz']);
this.set('Accept', 'application/json');
this.set({ Accept: 'text/plain', 'X-API-Key': 'tobi' });

@param {String|Object|Array} field
@param {String} val
@api public
Set header field to val or pass an object of header fields .