Skip to content

Commit

Permalink
Merge pull request #3 from dapize/fix/single-video-component
Browse files Browse the repository at this point in the history
fix(Single Video Component): Resetting the state if an error is geted
  • Loading branch information
lzdyes authored Mar 6, 2023
2 parents 0aded61 + a7141e7 commit 940c4b2
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "douyin-downloader",
"description": "A cross-platform download douyin video tool built with tauri",
"version": "0.1.8",
"version": "0.1.9",
"author": "lzdyes <[email protected]>",
"private": true,
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"package": {
"productName": "douyin-downloader",
"version": "0.1.8"
"version": "0.1.9"
},
"build": {
"distDir": "../dist",
Expand Down
6 changes: 5 additions & 1 deletion src/components/single/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,11 @@ const onSubmit = async () => {
status.value = t('video.downloading')
const data = await getVideo(id)
if (!data) return ElMessage.error(t('message.error_video_info'))
if (!data) {
isDownloading.value = false
status.value = ''
return ElMessage.error(t('message.error_video_info'))
}
const { desc, video } = data
const { vid } = video
Expand Down

0 comments on commit 940c4b2

Please sign in to comment.