Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to check user has logined and can retrieve feeds in Swift #215

Open
geek1250 opened this issue Nov 15, 2016 · 0 comments
Open

how to check user has logined and can retrieve feeds in Swift #215

geek1250 opened this issue Nov 15, 2016 · 0 comments

Comments

@geek1250
Copy link

Issue Summary

if app have run the logout vimeo method, this sentence " (VIMSession.sharedSession()?.account?.isAuthenticated() == nil)" will always be false, I thought it should be false so that the app can reopen URL

Reproduction Steps

I use the folloing code to logout
if ((VIMSession.sharedSession()?.account?.isAuthenticated()) != nil) {

        VIMSession.sharedSession()?.client.logoutWithCompletionBlock({ (vIMServerResponse, error) in
            if error == nil {
               
            }else {
                print("vimeo logout error: \(error)")
            }
            
        })

    }

And next time I want to login again with authorize with the these codes:
if (VIMSession.sharedSession()?.account?.isAuthenticated() == nil) {
let url = VIMSession.sharedSession()!.authenticator.codeGrantAuthorizationURL()
UIApplication.sharedApplication().openURL(url!)
}
else{
//retrieve feeds
}

I thought if (VIMSession.sharedSession()?.account?.isAuthenticated() == nil) should be true and reopen URL again if app have run the logout vimeo method.. But it always go to retrieve feeds part directly, and there is no feed found if app have run the logout vimeo method.

Expected Behavior

I thought if (VIMSession.sharedSession()?.account?.isAuthenticated() == nil) should be true and reopen URL again if app have run the logout vimeo method.. But it always go to retrieve feeds part directly, and there is no feed found if app have run the logout vimeo method.

Actual Behavior

it always go to retrieve feeds part directly, and there is no feed found if app have run the logout vimeo method.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant