mirror of
https://github.com/OAuthSwift/OAuthSwift.git
synced 2026-04-26 20:55:57 +03:00
[GH-ISSUE #228] How to access OAuthSwift WebView? #128
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#128
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 @SamL98 on GitHub (May 15, 2016).
Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/228
I am writing an app for iOS 8.0 using OAuthSwift. I am trying to implement logout functionality. I have already deleted cookies, cleared the cache, and synchronized nsuserdefaults. However, the web browser that oauthswift sends me to keeps me logged in. I read that I needed to also call:
<UIWebView>.stringByEvaluatingJavaScriptFromString("localStorage.clear();")!However, I don't know how to access the webview (or is it an SFSafariController?) to be able to clear it.
@phimage commented on GitHub (May 15, 2016):
Did you set the authorize_url_handler ?
If not, an external safari app is open and you cannot do anything I suppose...
You must set your custom handler to use your own web view, see demo app for instance
(SFSafariController is iOS9 and must be set explicitly)