Skip to content

Commit

Permalink
Merge pull request #330 from rmaes4/main
Browse files Browse the repository at this point in the history
Solve ReferenceError: Cookie is not defined
  • Loading branch information
blakebyrnes authored Nov 20, 2024
2 parents d86f5ed + 1bcbce3 commit 79e0987
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions agent/main/lib/Resources.ts
Original file line number Diff line number Diff line change
Expand Up @@ -656,6 +656,7 @@ export default class Resources
if (!Array.isArray(setCookie)) setCookie = [setCookie];
const defaultDomain = responseEvent.url.host;
for (const cookieHeader of setCookie) {
if (cookieHeader === '') continue;
const cookie = Cookie.parse(cookieHeader, { loose: true });
let domain = cookie.domain || defaultDomain;
// restore stripped leading .
Expand Down

0 comments on commit 79e0987

Please sign in to comment.