UIBarButtonItem + popover segue creates multiple popovers
I've currently have an iPad app with a UIToolbar containing two UIBarButtonItems, each of which is connected to a popover segue. When the user touches either of the UIBarButtonItems, the popover is created rather than toggled. This creates multiple, overlapping popovers. I've been able to close the previously created popover using the following code - (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { // First close the preferences popover if it's open per Apple guidelines if ([self.popoverA.popoverController isPopoverVisible]) { [self.popoverA.popoverController