The problem of using promise in vuex

Why output undefined instead of 123 here

methods: {
    release () {
      this.$store.dispatch("release").then((res) => {
        console.log(res)
      })
    }
}

vuex

actions: {
    release (val) {
      val.commit("release")
    }
}
mutations: {
    release () {
      return new Promise(function (resolve, reject) {
        resolve(123)
      })
    }
}
Aug.17,2021

to whom is your Promise in mutations ? Your dispatch executes the actions method
and commit does not support the return value

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e4bc61-44e7a.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e4bc61-44e7a.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?