module.exports=[624299,(e,r,t)=>{"use strict";var o=Object.defineProperty,n=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,c=Object.prototype.hasOwnProperty,f={},a={refreshToken:()=>d};for(var l in a)o(f,l,{get:a[l],enumerable:!0});r.exports=((e,r,t)=>{if(r&&"object"==typeof r||"function"==typeof r)for(let f of i(r))c.call(e,f)||void 0===f||o(e,f,{get:()=>r[f],enumerable:!(t=n(r,f))||t.enumerable});return e})(o({},"__esModule",{value:!0}),f);var p=e.r(310470),s=e.r(65048);async function d(e){let r=e?.project,t=e?.team;if(r||t){if(!r||!t){let e=(0,s.findProjectInfo)();r=r??e.projectId,t=t??e.teamId}}else{let e=(0,s.findProjectInfo)();r=e.projectId,t=e.teamId}if(!r)throw new p.VercelOidcTokenError("Failed to refresh OIDC token: No project specified. Try re-linking your project with `vc link`");let o=(0,s.loadToken)(r);if(!o||(0,s.isExpired)((0,s.getTokenPayload)(o.token),e?.expirationBufferMs)){let n=await (0,s.getVercelToken)({expirationBufferMs:e?.expirationBufferMs});if(!(o=await (0,s.getVercelOidcToken)(n,r,t)))throw new p.VercelOidcTokenError("Failed to refresh OIDC token");(0,s.saveToken)(o,r)}process.env.VERCEL_OIDC_TOKEN=o.token}}];

//# sourceMappingURL=0ozc_%40vercel_oidc_dist_token_0m1934l.js.map