jeyben / IOSLinkedInAPI

Simple and non intrusive library to get access tokens for LinkedIn using Oauth2.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Can't use from a Modal view controller

carlhunterroach opened this issue · comments

If one uses a modal segue then this code's view controller fails to open.

Work-around: don't use a modal segue.

Could you provide some more details?

To reproduce:

Create two View Controllers: A & B
Ctl+drag a segue from A to B and make it type Modal.
Then try and call your LinkedIn library from View Controller B and you'll get an error.

Then change the Segue type from Modal to Push. The error will be gone, your LinkedIn code will run and the LinkedIn login page within the WebView will appear (and work).

I'll be deleting this issue!

I completely missed the class method LIALinkedInHttpClient:clientForApplication:presentingViewController which allows one to pass in a view controller