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

Removing cookies are failing when the domain or path were set in the cookie #4

Closed
jherax opened this issue Apr 20, 2017 · 1 comment

Comments

@jherax
Copy link
Owner

jherax commented Apr 20, 2017

When trying to delete a cookie created by setting options.domain or options.path it is not working.

const cookieStore = new WebStorage('cookieStorage');

cookieStore.setItem('testing', [1,4,7], {
  domain: '.wordpress.com',
  expires: { minutes: 10 },
});

cookieStore.getItem('testing'); // ok, it exists
cookieStore.removeItem('testing'); // failing!
cookieStore.getItem('testing'); // failing, still exists!
jherax added a commit that referenced this issue Apr 20, 2017
jherax added a commit that referenced this issue Apr 20, 2017
jherax added a commit that referenced this issue Apr 20, 2017
jherax added a commit that referenced this issue Apr 20, 2017
jherax added a commit that referenced this issue Apr 20, 2017
jherax added a commit that referenced this issue Apr 21, 2017
jherax added a commit that referenced this issue Apr 21, 2017
jherax added a commit that referenced this issue Apr 21, 2017
@jherax jherax changed the title Removing cookies are failing when the domain or path were set in the options Removing cookies are failing when the domain or path were set in the cookie Apr 21, 2017
@jherax jherax closed this as completed in a4feafb Apr 21, 2017
jherax added a commit that referenced this issue Apr 21, 2017
…et in the cookie.

- setItem: prevents converting strings values to JSON to avoid extra quotes.
jherax added a commit that referenced this issue Apr 21, 2017
…et in the cookie.

- setItem: prevents converting strings values to JSON to avoid extra quotes.
@jherax
Copy link
Owner Author

jherax commented Apr 21, 2017

Take into account only the commit 42ea67e.
All other commits were generated because of the command:
git commit -a --amend --no-edit

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

No branches or pull requests

1 participant