Skip to content

Commit

Permalink
Merge pull request #1456 from matcic/1455
Browse files Browse the repository at this point in the history
fix: [#1455] Cookie container cache key
  • Loading branch information
capricorn86 authored Jun 20, 2024
2 parents 8da51ee + 2aab0d5 commit 3504a93
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/happy-dom/src/cookie/CookieContainer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@ export default class CookieContainer implements ICookieContainer {
public addCookies(cookies: ICookie[]): void {
const indexMap: { [k: string]: number } = {};
const getKey = (cookie: ICookie): string =>
`${cookie.key}-${cookie.originURL.hostname}-${
cookie.originURL.pathname
}-${typeof cookie.value}`;
`${cookie.key}-${cookie.originURL.hostname}-${cookie.path}-${typeof cookie.value}`;

// Creates a map of cookie key, domain, path and value to index.
for (let i = 0, max = this.#cookies.length; i < max; i++) {
Expand Down

0 comments on commit 3504a93

Please sign in to comment.