身份验证注销时出现权限错误:firebase/ionic/angularfire2

身份验证注销时出现权限错误:firebase/ionic/angularfire2,firebase,firebase-authentication,ionic3,angularfire2,Firebase,Firebase Authentication,Ionic3,Angularfire2,我有一个使用angularfire2和firebase的ionic3应用程序。我使用firbase auth登录到我的应用程序,并从firebase检索关于“currentChallenges”的对象。当我使用注销函数时,Firebase会抛出一个错误 错误消息: 权限\在/currentChallenge被拒绝:客户端没有权限 访问所需的数据 在我的auth.service.ts中,我使用以下功能注销: logout(){ this.isLoggedIn=false; 这是firebaseA

我有一个使用angularfire2和firebase的ionic3应用程序。我使用firbase auth登录到我的应用程序,并从firebase检索关于“currentChallenges”的对象。当我使用注销函数时,Firebase会抛出一个错误

错误消息:

权限\在/currentChallenge被拒绝:客户端没有权限 访问所需的数据

在我的auth.service.ts中,我使用以下功能注销:

logout(){
this.isLoggedIn=false;
这是firebaseAuth
作者
.signOut()。然后(()=>{
this.appCtrl.getRootNav().poptRoot();//root是登录页面
});
}
在注销前添加上述语句()

我也花了很多时间在这个问题上,没有发现任何线索。 希望这有帮助

private afDatabase: AngularFireDatabase,//blabla       
this.afDatabase.database.goOffline();//To solve the permission denied 문제.