cookies
cookies copied to clipboard
CookieManager.set response is undefined
Bug
Cookies aren't being set and the promise return 'done' is undefined. I'm using the iOS emulator, not sure if that's causing the issue.
Environment info
react-native info
output:
System: OS: macOS 10.15.4 CPU: (8) x64 Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz Memory: 1.28 GB / 16.00 GB Shell: 3.2.57 - /bin/bash Binaries: Node: 13.8.0 - /usr/local/bin/node Yarn: 1.22.0 - /usr/local/bin/yarn npm: 6.13.7 - /usr/local/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman SDKs: iOS SDK: Platforms: iOS 13.2, DriverKit 19.0, macOS 10.15, tvOS 13.2, watchOS 6.1 IDEs: Android Studio: 3.5 AI-191.8026.42.35.5900203 Xcode: 11.3.1/11C504 - /usr/bin/xcodebuild npmPackages: react: ~16.13.0 => 16.13.1 react-native: 0.61.5 => 0.61.5 npmGlobalPackages: create-react-native-web-app: 0.1.14 react-native-cli: 2.0.1 react-native-rename: 2.4.1 Library version: x.x.x
Steps To Reproduce
- Install the library
- Use CookieManager.set on iOS emulator ...
Describe what you expected to happen:
- Expect the cookie to be set, or fail
- Expect CookieManager.set to return 'done' as true / false
Reproducible sample code
const token = 'xxxxxxxxxxxxxxxxxxxxxxxxxxx'
const cookie = {
name: 'ssoid',
value: token,
path: '/',
version: '1',
expiration: '2025-05-30T12:30:00.00-05:00',
};
CookieManager.set(cookie).then(done => {
console.log('done ALWAYS undefined', done);
setCookieSet(done);
});
Any update on this one? I'm having the same issue