Swift: “Attempt to present UIAlertController whose view is not in the window hierarchy!”
问题 I'm trying to display a UIAlertController when a button is clicked (button click runs certain code, and depending on said outcome - the Alert shows up). The initial ViewController is the default one, and I've created a second one (ConsoleViewController). The user logs in, and upon successful log in, segues to the next view (ConsoleViewController), which displays data (which is in the viewDidLoad() section of the ConsoleViewController). Once the user clicks "Check In", the app captures the GPS