Fix alerting

This commit is contained in:
Pig Fang 2019-04-03 09:46:59 +08:00
parent 1f2d7a98ce
commit bf479ad6a6
2 changed files with 2 additions and 2 deletions

View File

@ -61,7 +61,7 @@ export default {
)
this.pending = false
if (errno === 0) {
await this.$alert({ message: msg, type: 'success' })
await this.$alert(msg)
window.location.href = `${blessing.base_url}/user`
} else {
this.message = msg

View File

@ -35,5 +35,5 @@ test('submit', async () => {
form.trigger('submit')
await wrapper.vm.$nextTick()
expect(Vue.prototype.$alert).toBeCalledWith({ message: 'ok', type: 'success' })
expect(Vue.prototype.$alert).toBeCalledWith('ok')
})