Skip to content

Commit

Permalink
Merge pull request #35 from ZyqGitHub1/dev
Browse files Browse the repository at this point in the history
fix search when keyword not m3u8 link
  • Loading branch information
ZyqGitHub1 committed Aug 5, 2019
2 parents 0b48b0a + 8b7f1de commit b0bb5b1
Showing 1 changed file with 16 additions and 10 deletions.
26 changes: 16 additions & 10 deletions src/layouts/Home.vue
Expand Up @@ -264,18 +264,24 @@ export default {
const { pathname } = url;
const extname = path.extname(pathname);
if (extname === '.m3u8') {
this.$q.dialog({
title: '播放',
message: '检测到搜索参数是hls流链接,是否播放',
cancel: true,
persistent: true,
}).onOk(() => {
this.directVideo();
}).onCancel(() => {
this.$store.commit('setKeyWord', this.keyWord);
});
this.$q
.dialog({
title: '播放',
message: '检测到搜索参数是hls流链接,是否播放',
cancel: true,
persistent: true,
})
.onOk(() => {
this.directVideo();
})
.onCancel(() => {
this.$store.commit('setKeyWord', this.keyWord);
});
} else {
this.$store.commit('setKeyWord', this.keyWord);
}
} catch (error) {
this.$store.commit('setKeyWord', this.keyWord);
console.error(error);
}
} else {
Expand Down

0 comments on commit b0bb5b1

Please sign in to comment.