File tree Expand file tree Collapse file tree 2 files changed +4
-15
lines changed
Example/ios/AppAuthExample Expand file tree Collapse file tree 2 files changed +4
-15
lines changed Original file line number Diff line number Diff line change 8
8
*/
9
9
10
10
#import < UIKit/UIKit.h>
11
+ #import < RNAppAuth/RNAppAuthAuthorizationFlowManager.h>
11
12
12
- @interface AppDelegate : UIResponder <UIApplicationDelegate>
13
+ @interface AppDelegate : UIResponder <UIApplicationDelegate, RNAppAuthAuthorizationFlowManager >
13
14
@property (nonatomic , strong , nullable ) UIWindow *window;
15
+ @property (nonatomic , weak )id <RNAppAuthAuthorizationFlowManagerDelegate>authorizationFlowManagerDelegate;
14
16
@end
15
17
Original file line number Diff line number Diff line change 10
10
#import " AppDelegate.h"
11
11
#import < React/RCTBundleURLProvider.h>
12
12
#import < React/RCTRootView.h>
13
- #import < AppAuth/AppAuth.h>
14
- #import < RNAppAuth/RNAppAuthAuthorizationFlowManager.h>
15
-
16
- @interface AppDelegate ()<RNAppAuthAuthorizationFlowManager> {
17
- id <OIDAuthorizationFlowSession> _currentSession;
18
- }
19
- @end
20
13
21
14
@implementation AppDelegate
22
15
23
- -(void )setCurrentAuthorizationFlowSession : (id <OIDAuthorizationFlowSession>)session {
24
- _currentSession = session;
25
- }
26
-
27
16
- (BOOL )application : (UIApplication *)application didFinishLaunchingWithOptions : (NSDictionary *)launchOptions
28
17
{
29
18
NSURL *jsCodeLocation;
@@ -45,9 +34,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
45
34
}
46
35
47
36
- (BOOL )application : (UIApplication *)app openURL : (NSURL *)url options : (NSDictionary <NSString *, id> *)options {
48
- BOOL shouldOpenUrl = [_currentSession resumeAuthorizationFlowWithURL: url];
49
- _currentSession = nil ;
50
- return shouldOpenUrl;
37
+ return [self .authorizationFlowManagerDelegate resumeExternalUserAgentFlowWithURL: url];
51
38
}
52
39
53
40
@end
You can’t perform that action at this time.
0 commit comments