SCLAlertView-Swift icon indicating copy to clipboard operation
SCLAlertView-Swift copied to clipboard

'shared' is unavailable: Use view controller based solutions where appropriate instead.

Open Nikooos opened this issue 7 years ago • 2 comments

I've tried searching all over the web, but I couldn't find a working solution yet.

at these lines: UIApplication.shared.keyWindow! as UIWindow UIApplication.shared.keyWindow?.subviews

I get the error: 'shared' is unavailable: Use view controller based solutions where appropriate instead.

Anyone has an idea to fix this?

Nikooos avatar May 07 '18 06:05 Nikooos

Currently i'm working around this by adding it as a embedded framework, but I would rather use cocoapods.

Nikooos avatar May 07 '18 07:05 Nikooos

Hi, I assume you have an extension on your app. SCAlertView target inside Pod project -> Build Settings -> require only app-extension-safe api -> No.

shalamowww avatar Jul 23 '18 18:07 shalamowww