Skip to content

Commit

Permalink
Code was duplicated
Browse files Browse the repository at this point in the history
  • Loading branch information
Sean Luthjohn committed Jul 6, 2018
1 parent b519a58 commit 69924ba
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/components/Login.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,8 @@ export default {
},
methods: {
signIn() {
const email = this.email;
const pwd = this.password;
firebase.auth().signInWithEmailAndPassword(email, pwd).then((user) => {
localStorage.user = JSON.stringify(user);
this.$store.dispatch('signUserIn', { email: this.email, password: this.password });
this.$store.dispatch('signUserIn', { email: this.email, password: this.password })
.then(() => {
this.$store.dispatch('initializeDB');
this.$router.replace('overview');
}, (err) => {
Expand Down

0 comments on commit 69924ba

Please sign in to comment.