Is this a support request?
This issue tracker is maintained by LaunchDarkly SDK developers and is intended for feedback on the SDK code. If you're not sure whether the problem you are having is specifically related to the SDK, or to the LaunchDarkly service overall, it may be more appropriate to contact the LaunchDarkly support team; they can help to investigate the problem and will consult the SDK team if necessary. You can submit a support request by going here or by emailing [email protected].
Note that issues filed on this issue tracker are publicly accessible. Do not provide any private account information on your issues. If your problem is specific to your account, you should submit a support request as described above.
Describe the bug
Given an instantiated client LDClient, calling .close() will cause any future method calls on that client to throw an error in from the swift code.
To reproduce
Configure a client. Call .close() then try calling a flag check.
Expected behavior
The subsequent flag check should resolve to the given default value.
Logs
LaunchdarklyReactNativeClient.swift:239:31
Swift runtime failure: Unexpectedly found nil while unwrapping an Optional value
(seen this same error on other calls from that class as well)
SDK version
This error was seen on both 4.0.2 and 4.1.1
Language version, developer tools
React Native/Xcode
OS/platform
Error only occurs on iOS, version seems to not matter.