sammcewan / WYPopoverController

WYPopoverController is for the presentation of content in popover on iPhone / iPad devices. Very customizable.
Other
253 stars 74 forks source link

UIViewController(popoverController's contentViewController) was deallocated while key value observers were still registered with it #5

Closed morgman closed 9 years ago

morgman commented 9 years ago

Since I noticed that new fork that might be actively maintained I decided to move this bug over here.

This was reported in the original baseline with no answers. I've run into the same issue:

UIViewController(popoverController's contentViewController) was deallocated while key value observers were still registered with it...

Two taps on an actual device (not simulator) in quick succession reliably cause the error. Seems the second tap starts a new popover which attempts to dealloc the first instance before the first one can finish initializing.

I'm looking over the code but am open to suggestions on how to prevent this. Ideas?

gitsumakwel commented 9 years ago

Singleton? maybe or disable button?

vitalys commented 9 years ago

Thanks for reporting. I saw this problem in my project, but wasn't able to reproduce it. I'll try to fix it in few days.

sammcewan commented 9 years ago

I've added a quick fix for this.