Avatar
https://developer.apple.com/documentation/uikit/uiviewcontroller/1621505-dismiss
If you present several view controllers in succession, thus building a stack of presented view controllers, calling this method on a view controller lower in the stack dismisses its immediate child view controller and all view controllers above that child on the stack.