1
0
mirror of https://github.com/chinchang/web-maker.git synced 2025-07-18 12:31:12 +02:00

add events

This commit is contained in:
Kushagra Gour
2018-01-19 11:42:53 +05:30
parent 8acf653a5c
commit ca69ae77d2
3 changed files with 9 additions and 3 deletions

View File

@@ -1,3 +1,5 @@
/* global trackEvent */
window.logout = function logout() {
firebase.auth().signOut();
};
@@ -17,7 +19,9 @@ function login(providerName) {
return firebase
.auth()
.signInWithPopup(provider)
.then(function() {})
.then(function() {
trackEvent('fn', 'loggedIn', providerName);
})
.catch(function(error) {
alert(
'You have already signed up with the same email using different social login'