Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix eraseCookies domain bug and expand tests #719

Open
wants to merge 15 commits into
base: master
Choose a base branch
from

Conversation

imnasnainaec
Copy link

@imnasnainaec imnasnainaec commented Aug 13, 2024

Improvements in this pr:

  • Expand docs for eraseCookies
  • In eraseCookiesHelper, don't use erase(cookieName); because that causes a bug, deleting unintended cookies when a domain was specified; rather, allow erase(cookieName, customDomain); to cover the case when customDomain is empty
  • In the erase function, only add a . to the start of the domain if it's nonempty and doesn't already start with a .
  • Update cookie erasure tests to verify the cookie is there before it's erased
  • Add more tests to ensure that a wrong path or wrong domain will not delete a cookie

Copy link

vercel bot commented Aug 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
cookieconsent-docs ⬜️ Ignored (Inspect) Visit Preview Aug 14, 2024 2:07pm

Copy link

netlify bot commented Aug 13, 2024

Deploy Preview for cookieconsentv3-playground canceled.

Name Link
🔨 Latest commit bebdd6f
🔍 Latest deploy log https://app.netlify.com/sites/cookieconsentv3-playground/deploys/66bcb9fec55c270008dafa7d

@imnasnainaec imnasnainaec changed the title Add more path/domain tests for eraseCookies Add more tests and info for eraseCookies Aug 14, 2024
@imnasnainaec imnasnainaec changed the title Add more tests and info for eraseCookies Add eraseCookies tests and fix domain bug Aug 14, 2024
@imnasnainaec imnasnainaec changed the title Add eraseCookies tests and fix domain bug Fix eraseCookies domain bug and expand tests Aug 14, 2024
@imnasnainaec imnasnainaec marked this pull request as ready for review August 22, 2024 14:35
Copy link

stale bot commented Sep 21, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Sep 21, 2024
@imnasnainaec
Copy link
Author

@orestbida You had a comment about this pr here, which I responded to. I'm not sure if there were other things you wish to review or test.

@stale stale bot removed the stale label Sep 23, 2024
Copy link

stale bot commented Oct 28, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Oct 28, 2024
@imnasnainaec
Copy link
Author

Improvements in this pr:

  • Expand docs for eraseCookies
  • In eraseCookiesHelper, don't use erase(cookieName); because that causes a bug, deleting unintended cookies when a domain was specified; rather, allow erase(cookieName, customDomain); to cover the case when customDomain is empty
  • In the erase function, only add a . to the start of the domain if it's nonempty and doesn't already start with a .
  • Update cookie erasure tests to verify the cookie is there before it's erased
  • Add more tests to ensure that a wrong path or wrong domain will not delete a cookie

@stale stale bot removed the stale label Oct 29, 2024
Copy link

stale bot commented Dec 3, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 3, 2024
@orestbida orestbida removed the stale label Dec 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants