feat: use async / await where it makes sense
This commit is contained in:
parent
a776e1d2f3
commit
bb94c1ba3a
74 changed files with 1458 additions and 1662 deletions
|
|
@ -35,12 +35,10 @@ export default {
|
|||
},
|
||||
},
|
||||
methods: {
|
||||
deleteNamespace() {
|
||||
this.$store.dispatch('namespaces/deleteNamespace', this.namespace)
|
||||
.then(() => {
|
||||
this.$message.success({message: this.$t('namespace.delete.success')})
|
||||
this.$router.push({name: 'home'})
|
||||
})
|
||||
async deleteNamespace() {
|
||||
await this.$store.dispatch('namespaces/deleteNamespace', this.namespace)
|
||||
this.$message.success({message: this.$t('namespace.delete.success')})
|
||||
this.$router.push({name: 'home'})
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue