File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -105,13 +105,18 @@ public final class IterableAPI: NSObject {
105105 launchOptions: [ UIApplication . LaunchOptionsKey : Any ] ? ,
106106 config: IterableConfig = IterableConfig ( ) ,
107107 apiEndPointOverride: String ? = nil ,
108- linksEndPointOverride: String ? = nil ) {
108+ linksEndPointOverride: String ? = nil ,
109+ callback: ( ( Bool ) -> Void ) ? = nil ) {
109110 internalImplementation = IterableAPIInternal ( apiKey: apiKey,
110111 launchOptions: launchOptions,
111112 config: config,
112113 apiEndPointOverride: apiEndPointOverride,
113114 linksEndPointOverride: linksEndPointOverride)
114- _ = internalImplementation? . start ( )
115+ _ = internalImplementation? . start ( ) . onSuccess { _ in
116+ callback ? ( true )
117+ } . onError { _ in
118+ callback ? ( false )
119+ }
115120 }
116121
117122 // MARK: - SDK
You can’t perform that action at this time.
0 commit comments