Skip to content
This repository has been archived by the owner on Feb 27, 2019. It is now read-only.

Avoid calling getResultsForConfig twice #126

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

bre7
Copy link
Collaborator

@bre7 bre7 commented Nov 10, 2015

getResultsForConfig was being called before and in allAuthorized

@nickoneill
Copy link
Owner

Is there a particular case where this is called twice? It doesn't look like it happens always...

Also, I just merged this locally with #115 and it won't show the UI using the example app, just returns returned results [LocationInUse Unknown, Notifications Unknown, Contacts Unknown] for a fresh simulator.

@bre7
Copy link
Collaborator Author

bre7 commented Nov 28, 2015

Flow:
detectAndCallback
--> getResultsForConfig
----> allAuthorized
------> getResultsForConfig

@bre7
Copy link
Collaborator Author

bre7 commented Nov 28, 2015

Also, I just merged this locally with #115 and it won't show the UI using the example app, just returns returned results [LocationInUse Unknown, Notifications Unknown, Contacts Unknown] for a fresh simulator.

Yeah, that's the problem with the fix: #125 (comment)

@nickoneill
Copy link
Owner

OK, I'll deal with that one first, then I'll come back to figure out what's going on here.

@nickoneill
Copy link
Owner

I don't think that's the same issue as #125 - this was just me using the standard example project, not the special no UI case that we're dealing with there.

@bre7
Copy link
Collaborator Author

bre7 commented Nov 28, 2015

The problem in #125 was that results would say one thing, while statusNotifications would report another (the correct one).

singlePscope.onAuthChange = { (finished, results) in
    print("got results \(results)")
    print("statusNotifications \(self.singlePscope.statusNotifications())")
}

And also, show isn't working in this branch

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

Successfully merging this pull request may close these issues.

2 participants