vuetifyjs / vuex

📚 Mono-repo structure for Vuetify Vuex modules
Other
43 stars 11 forks source link

[Bug report] After sign out error #17

Open Neo39982 opened 5 years ago

Neo39982 commented 5 years ago

Errr

Chonne commented 5 years ago

I've encountered this issue as well. In my browser, the message only appears if I've opened the Vue Chrome devtools. Otherwise it does sign out the user, but returns undefined:

import { mapActions } from 'vuex';

export default {
  methods: {
    ...mapActions('cognito', ['signOut']),
    async logOut() {
      try {
        const result = await this.signOut();
        // this logs "undefined"
        console.log(result);
      } catch (err) {
        // no logs are displayed if the Vue devtools haven't been opened
        console.error(err);
      }
    },
  },
};