Skip to content
This repository was archived by the owner on Sep 26, 2022. It is now read-only.

Fix various cookies issues#171

Merged
thomasvidas merged 6 commits intocapacitor-community:masterfrom
FelixSchwarzmeier:fix-cookies-issues
Nov 10, 2021
Merged

Fix various cookies issues#171
thomasvidas merged 6 commits intocapacitor-community:masterfrom
FelixSchwarzmeier:fix-cookies-issues

Conversation

@FelixSchwarzmeier
Copy link
Contributor

This PR fixes the following cookies issues:

  • Fix setCookie() on android. Currently, it is not possible to set a Set-Cookie HTTP response header as part of the cookie value due to the encoding step. For instance, setting a cookie with the value en; Max-Age=5 will be replaced to en%3B+Max-Age%3D5 and hence Max-Age will not be taken into account. Thus, this PR removes the encoding/decoding steps on android.
  • clearCookies() on android is implemented differently than on ios. On android all cookies are removed, on ios only those from the passed URL. This PR fixes this issue by introducing a new method clearAllCookies() and adjusting the respective methods on android/ios.
  • Fix definition for getCookiesMap and add implementation for getCookiesMap() on ios.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants