0

Warning: Attempt to present on whose view is not in the window hierarchy!

I presented firebase AuthViewController in viewDidLoad and getting this error. But when I present that AuthViewController by a button click or in viewDidAppear, it works perfect.

Robert Dresler
  • 10,580
  • 2
  • 22
  • 40
Sahil
  • 59
  • 11
  • check it out https://stackoverflow.com/questions/11862883/attempt-to-present-uiviewcontroller-on-uiviewcontroller-whose-view-is-not-in-the – Taras Chernyshenko Jan 14 '19 at 13:55
  • Thnx for the answer, works for me – Sahil Jan 14 '19 at 14:00
  • Possible duplicate of [Attempt to present UIViewController on UIViewController whose view is not in the window hierarchy](https://stackoverflow.com/questions/11862883/attempt-to-present-uiviewcontroller-on-uiviewcontroller-whose-view-is-not-in-the) – Tamás Sengel Jan 14 '19 at 15:07
  • It's probably a coding issue but since the code was not included in the question, it would be hard to determine the specific cause. Please take a moment and review [How do I ask a good question?](https://stackoverflow.com/help/how-to-ask) and [How to create a Minimal, Complete, and Verifiable example](https://stackoverflow.com/help/mcve) – Jay Jan 14 '19 at 17:25

0 Answers0