I have a Notification Extension in my app. However, when I build my app it conflicts with the pod FBSDKLoginKit
. It gives me the following error in the FBSDKCoreKit:
'sharedApplication' is unavailable: not available on iOS (App Extension) - Use view controller based solutions where appropriate instead.
My Podfile looks like this (I've missed out irrelevant pods):
workspace 'MyApp'
platform :ios, '10.0'
target 'MyApp' do
use_frameworks!
project 'MyApp.xcodeproj'
pod 'FBSDKLoginKit'
pod 'OneSignal', '>= 2.6.2', '< 3.0'
target 'OneSignalNotificationServiceExtension' do
pod 'OneSignal', '>= 2.6.2', '< 3.0'
end
end
How do I fix this?