AnderGoig / SwiftInstagram

Instagram API client written in Swift

Home Page:https://git.io/vdNAn

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Not redirecting to other page after successful login

dineshguptha opened this issue · comments

Hello, after successful login page is not redirecting to root view controller.
simulator screen shot - iphone 8 plus - 2018-06-11 at 17 29 37

let api = Instagram.shared
// Login
api.login(from:self.navigationController!, withScopes: [.publicContent], success: {
// Do your stuff here ...
}, failure: { error in
print(error.localizedDescription)
})
This Is the code am using for login.

I am using the same code and it is working for me, are you redirected to different ViewController? if so, make sure that the desired viewController is also the root

Same @dineshguptha problem...
This issue appear without many reason while worked fine before and nothing change in my code...

Same problem on my side. I guess it’s related to changes that were done on Instagram API

hello, I am facing a similar issue: I have used the same code of Dinesh and just after tapping the save info button, I got the following page of the InstagramViewController. Anyway, the navigation controller does not pop the view controller and going back bring to the previous view controller without getting the success handler called
simulator screen shot - iphone se - 2018-07-19 at 18 24 13

I just tested it and had no problem. Are you guys unchecking the "Disable implicit OAuth" option in the Instagram client? (https://github.com/AnderGoig/SwiftInstagram/wiki/Authentication#swiftinstagram-authentication)

FWIW, I'm seeing this behavior if I attempt to use the "Continue with Facebook" option on the login screen. If I'm logging in with a username/password, it behaves as expected.

@AnderGoig I have the same issue like @panchsheelmind
I really have no idea what I am doing wrong, but its simply loading instagram first screen...
"Disable implicit OAuth" is disabled, but I have no idea why I need redirect URI . I just put simply put https://thispic.io/ but no idea if it affects.

I entered in sdk and printed url, then opened in browser, and it redirected succesffully to:
http://www.thispic.io/#access_token=7276677373.b4ceae8.e33aa2d3e0d0451c83a8391896d93e71
which is fine, I think. But in app, its not working.

Any idea ?

Really appreciate your help.

Maybe this will help

13

Any update on this?

For some reasons, seems its not working ok.
Here is one case:
If IG found unsecure login, they will send you a code, you enter code corectly, and no callback back to app, only it loads www.instagram.com in that webView.

Anyway, @AnderGoig did a very great job here, but IG messed everything.