MCPcopy Create free account
hub / github.com/github/gh-aw / mergeAuthorizationHeader

Function mergeAuthorizationHeader

actions/setup/js/action_setup_otlp.cjs:60–63  ·  view source on GitHub ↗

* @param {string} headers * @param {string} token * @returns {string}

(headers, token)

Source from the content-addressed store, hash-verified

58 * @returns {string}
59 */
60function mergeAuthorizationHeader(headers, token) {
61 if (hasAuthorizationHeader(headers)) return headers;
62 return (headers ? `${headers},` : "") + "Authorization=Bearer " + token;
63}
64
65/**
66 * @param {string} endpointsRaw

Callers 2

runFunction · 0.85

Calls 1

hasAuthorizationHeaderFunction · 0.85

Tested by

no test coverage detected