mirror of https://github.com/Kylart/KawAnime.git
Fix bug where cancelling path choice dialog would end up not being able to open any more dialog + random dialog appearance
This commit is contained in:
parent
769d89838e
commit
ba518703f3
|
@ -57,6 +57,8 @@ exports.openExternal = (query, res) => {
|
|||
}
|
||||
|
||||
sendRes(res, result)
|
||||
} else {
|
||||
sendEmptyRes(res)
|
||||
}
|
||||
})
|
||||
break
|
||||
|
|
|
@ -327,17 +327,21 @@ export default {
|
|||
async changePath ({commit, dispatch}) {
|
||||
const {data} = await axios.get('openThis?type=dialog')
|
||||
|
||||
commit('emptyLocals')
|
||||
commit('setCurrentDir', data.path)
|
||||
dispatch('refreshLocal')
|
||||
if (data) {
|
||||
commit('emptyLocals')
|
||||
commit('setCurrentDir', data.path)
|
||||
dispatch('refreshLocal')
|
||||
}
|
||||
},
|
||||
async changePathWithConfig ({commit, dispatch}) {
|
||||
const {data} = await axios.get('openThis?type=dialog')
|
||||
|
||||
commit('emptyLocals')
|
||||
commit('setCurrentDir', data.path)
|
||||
commit('setConfigDir', data.path)
|
||||
dispatch('refreshLocal')
|
||||
if (data) {
|
||||
commit('emptyLocals')
|
||||
commit('setCurrentDir', data.path)
|
||||
commit('setConfigDir', data.path)
|
||||
dispatch('refreshLocal')
|
||||
}
|
||||
},
|
||||
async openNewsLink ({state}, link) {
|
||||
log(`Opening ${link}`)
|
||||
|
|
Loading…
Reference in New Issue