File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed
AferoSwiftSDK/AFNetworking
Examples/AferoLab/AferoLab/Base.lproj Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -334,19 +334,19 @@ extension AFNetworkingAferoAPIClient: AferoAPIClientProto {
334
334
return
335
335
}
336
336
337
- var oAuthBaseUrl : URL ?
338
- if let scheme = oAuthOpenIdURL ? . scheme , let host = oAuthOpenIdURL ? . host {
339
- oAuthBaseUrl = URL ( string : " \( scheme ) :// \( host ) /token " ) ;
340
- }
337
+ let oAuthTokenUrl : String ? = oAuthOpenIdURL != nil ? " \( oAuthOpenIdURL! . absoluteString ) /token " : nil
338
+
339
+ DDLogInfo ( " RefreshUrl \( String ( describing : oAuthTokenUrl ) ) " , tag : TAG )
340
+
341
341
342
342
let oauthManager = AFOAuth2Manager (
343
- baseURL: oAuthBaseUrl ?? apiBaseURL,
343
+ baseURL: apiBaseURL,
344
344
clientID: oauthClientId,
345
345
secret: oauthClientSecret
346
346
)
347
347
348
348
oauthManager. authenticateUsingOAuth (
349
- withURLString: oAuthBaseUrl ? . path ?? type ( of: self ) . OAUTH_TOKEN_PATH,
349
+ withURLString: oAuthTokenUrl ?? type ( of: self ) . OAUTH_TOKEN_PATH,
350
350
refreshToken: credential. refreshToken,
351
351
success: {
352
352
credential in
Original file line number Diff line number Diff line change 1063
1063
<navigationController title =" AferoLab" automaticallyAdjustsScrollViewInsets =" NO" id =" YYV-1Q-Ilk" customClass =" AferoLabNavigationController" customModule =" AferoLab" customModuleProvider =" target" sceneMemberID =" viewController" >
1064
1064
<toolbarItems />
1065
1065
<navigationBar key =" navigationBar" contentMode =" scaleToFill" largeTitles =" YES" id =" NJL-Rb-4Ot" >
1066
- <rect key =" frame" x =" 0.0" y =" 20" width =" 320" height =" 92 .5" />
1066
+ <rect key =" frame" x =" 0.0" y =" 20" width =" 320" height =" 98 .5" />
1067
1067
<autoresizingMask key =" autoresizingMask" />
1068
1068
<color key =" tintColor" red =" 1" green =" 1" blue =" 1" alpha =" 1" colorSpace =" calibratedRGB" />
1069
1069
<color key =" barTintColor" red =" 0.99987393619999998" green =" 0.67495071890000002" blue =" 0.24090552330000001" alpha =" 1" colorSpace =" custom" customColorSpace =" sRGB" />
2904
2904
<navigationController automaticallyAdjustsScrollViewInsets =" NO" id =" sf2-PJ-NAK" sceneMemberID =" viewController" >
2905
2905
<toolbarItems />
2906
2906
<navigationBar key =" navigationBar" contentMode =" scaleToFill" insetsLayoutMarginsFromSafeArea =" NO" id =" qhz-SK-aoL" >
2907
- <rect key =" frame" x =" 0.0" y =" 0.0" width =" 320" height =" 44 " />
2907
+ <rect key =" frame" x =" 0.0" y =" 0.0" width =" 320" height =" 50 " />
2908
2908
<autoresizingMask key =" autoresizingMask" />
2909
2909
</navigationBar >
2910
2910
<nil name =" viewControllers" />
3061
3061
</designables >
3062
3062
<inferredMetricsTieBreakers >
3063
3063
<segue reference =" 0Ax-oZ-siA" />
3064
- <segue reference =" lHG-0u-qkB " />
3064
+ <segue reference =" cdP-6b-q7e " />
3065
3065
<segue reference =" iph-Rf-zkF" />
3066
3066
</inferredMetricsTieBreakers >
3067
3067
<color key =" tintColor" red =" 0.94509804249999996" green =" 0.59215688710000003" blue =" 0.21568629149999999" alpha =" 1" colorSpace =" custom" customColorSpace =" displayP3" />
You can’t perform that action at this time.
0 commit comments