launchdarkly / ios-client-sdk

LaunchDarkly Client-side SDK for iOS (Swift and Obj-C)
https://docs.launchdarkly.com/sdk/client-side/ios
Other
70 stars 84 forks source link

Only import WatchKit if running on watchOS #183

Closed ugiacoman closed 5 years ago

ugiacoman commented 5 years ago

Problem

In Xcode 11, you cannot import WatchKit on iOS simulators.

Error:

"WatchKit" is not available when building for iOS Simulator. Consider using `#if !os(iOS)` to conditionally import this framework.

Solution

Testing

torchhound commented 5 years ago

Hi @ugiacoman, thanks for putting in a PR! I'll do some testing on this and get back to you.

torchhound commented 5 years ago

Tested and LGTM!

torchhound commented 5 years ago

This is now available in the iOS Client 4.1.2 release, thanks again for the PR!