Ios popToRootViewController后UITabBar消失

Ios popToRootViewController后UITabBar消失,ios,swift,popviewcontroller,Ios,Swift,Popviewcontroller,我的应用程序简化视图层次结构如下所示: <UITabBarController>, | <UINavigationController> | | <HomeViewController> | <UINavigationController> | | <ChatViewController> | <UINavigationController> | | <Profil

我的应用程序简化视图层次结构如下所示:

<UITabBarController>,
   | <UINavigationController>
   |    | <HomeViewController>
   | <UINavigationController>
   |    | <ChatViewController>
   | <UINavigationController>
   |    | <ProfileViewController>
  • 当重定向到ChatViewController时,UITabBar已消失,并在同一位置显示黑色视图

  • 我试过所有控制器,但没有效果

    override func viewWillAppear(_ animated: Bool) {
        super.viewWillAppear(animated)
        self.tabBarController?.tabBar.isHidden = true
    }
    
    这是因为
    userProfileVC.hidesBottomBarWhenPushed=true
    吗?您是否遇到过这个问题?
    谢谢

    当您弹出时,您必须将tabBar.ishiden属性设置为false。是的,它是正确的。您能回答这个问题以便我可以对其进行验证吗
    override func viewWillAppear(_ animated: Bool) {
        super.viewWillAppear(animated)
        self.tabBarController?.tabBar.isHidden = true
    }