client/contexts/AuthContext.js
//this function writes user data into the user database
this function writes user data into the user database
this function writes user data into the user database
function writeUserData(user) {
    var userReff = ref(database, "users/" + user.uid + "/userinfo");
    set(userReff, user);
  }
function writeUserData ( user ) { var userReff = ref ( database , "users/" + user . uid + "/userinfo" ) ; set ( userReff , user ) ; }
this function writes user data into the user database
this function writes user data into the user database
// currentUser.updateEmail(user.email);