AnderGoig / SwiftInstagram

Instagram API client written in Swift
https://git.io/vdNAn
MIT License
578 stars 81 forks source link

Getting nil while calling the login method. #41

Open ambujshukla-cdn opened 6 years ago

ambujshukla-cdn commented 6 years ago

Checklist

Expected Behavior

  1. Should not crash at the starting only when calling the login method.

Actual Behavior

  1. Getting crash on calling this - api.login(from: navigationController!, success: { // Do your stuff here ... }, failure: { error in print(error.localizedDescription) }) Error - Thread 1: EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)

Steps to Reproduce the Problem

  1. Just call this :- let api = Instagram.shared

    // Login
    api.login(from: navigationController!, success: {
        // Do your stuff here ...
    }, failure: { error in
        print(error.localizedDescription)
    })

Specifications

AnderGoig commented 6 years ago

Hi @ambujshukla-cdn, did you follow all the previous steps https://github.com/AnderGoig/SwiftInstagram/wiki/Authentication#swiftinstagram-authentication?

amith-ranasinghe commented 5 years ago

@ambujshukla-cdn embed your controller to navigation controller.