mirror of
https://github.com/OAuthSwift/OAuthSwift.git
synced 2026-04-26 20:55:57 +03:00
[GH-ISSUE #706] the closure for the authorize function callback is not being executed at all. #458
Labels
No labels
bug
cocoapod
duplicate
enhancement
feature-request
help wanted
help wanted
invalid
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/OAuthSwift#458
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Monkey-X-Byte on GitHub (Apr 11, 2023).
Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/706
Description:
During my usage of OAuthSwift 2.2.0, the closure for the authorize function callback is not being executed at all.
let oauth = OAuth2Swift(consumerKey: appId, consumerSecret: appSecret, authorizeUrl: authorizeUrl, accessTokenUrl: accessTokenUrl, responseType: responseType, contentType: nil)
oauth.allowMissingStateCheck = true
#if os(iOS)
oauth.authorizeURLHandler = SafariURLHandler(viewController: viewController, oauthSwift: oauth)
#endif
self.oauth = oauth
_ = oauth.authorize(withCallbackURL: URL(string: callbackUrl), scope: scope, state: state, parameters: authorizeParameters, completionHandler: { result in
switch result {
case .success(let token):
completion(.success(token))
case .failure(let error):
completion(.failure(error))
}
})
OAuth Provider? (Baidu):
OAuth Version:
OS (Please fill the version) :
Installation method:
Library version:
Xcode version:
11.4 (Swift 5.2)
11.x (Swift 5.1)
10.x (Swift 5.0)
[x ] other: (XCode14.3.)
objective c
@phimage commented on GitHub (Apr 11, 2023):
let oauth = OAuth2Swift
retain it in memory
@Monkey-X-Byte commented on GitHub (Apr 12, 2023):
You may not have seen that I mentioned the issue of retaining in memory. I'm encountering this issue while using OAuth2Swift in a SwiftUI application