Advertisement
Guest User

Untitled

a guest
Feb 24th, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.29 KB | None | 0 0
  1. const firebaseSave = async function(data) {
  2. const uid = firebase.auth().currentUser.uid
  3.  
  4. const profilePath = `users/${uid}`
  5. const profileData = {
  6. name: data.name,
  7. }
  8.  
  9. const userRef = firebaseDb.child(profilePath)
  10. await userRef.set(profileData)
  11.  
  12. callback()
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement