Hello i am trying to use react-router with firebase. but it gives me this error.
Cannot read property 'props' of null
this is exactly code, where i am using my react-router
Down code is on component as loginpanel component.
else if (this.email.value === currentObject.username && this.password.value === currentObject.password && user_id)
 {
     var data25 = '';
     var groupid = '';
     var query = firebase.database().ref("/Users_group").orderByChild('id').equalTo(user_id);
     query.on("child_added", function hello (snapshot) {
         data25 = snapshot.val();
         groupid = data25.User_Group_id;
         AppActions.createComment(currentObject.username, currentObject.password, user_id, groupid);
//error is here,
         this.props.router.push('Index');
     },()=>{
     });
 }
my react router is declared on main.jsx my react-router looks like this.
       <Router history={hashHistory}>
      <Route path="/" component={Loginpanel}/>
      <Route path="Index" component={Index}/>
      <Route path="Form" component={Form} />
      <Route path="Checkindex" component={Index}/>
      <Route path="Signup" component={Signup}/>
      <Route path="Admin" component={Admin}/>
      <Route path="AdminEditDetails" component={AdminEditDetails}/>
      <Route path="AdminDetails" component={AdminDetails}/>
     </Router>,