Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function App ({ id, privateKey, baseUrl, cache }) {
const state = {
id,
privateKey,
request: baseUrl ? request.defaults({ baseUrl }) : request,
cache: cache || getCache()
}
const api = {
getSignedJsonWebToken: getSignedJsonWebToken.bind(null, state),
getInstallationAccessToken: getInstallationAccessToken.bind(null, state)
}
return api
}