diff --git a/assets/api/nyaa.js b/assets/api/nyaa.js index 4418976..cdf3932 100644 --- a/assets/api/nyaa.js +++ b/assets/api/nyaa.js @@ -30,7 +30,7 @@ const download = (req, res) => { console.log(searchData) - const term = `[${searchData.fansub}]+${searchData.quality}+${searchData.name}` + const term = `[${searchData.fansub}]+${searchData.quality}+${searchData.name}+-unofficial` if (choice === 'si') { nyaa.searchSi(term).then((data) => { @@ -84,7 +84,7 @@ const getLatest = (url, res) => { let toReturn = [] if (choice === 'si') { - nyaa.searchSi(`[${fansub}] ${quality}`, 18).then((data) => { + nyaa.searchSi(`[${fansub}] ${quality} -unofficial`, 18).then((data) => { for (let i = 0; i < 18; ++i) { const realName = data[i].title[0].replace(' VOSTFR', '') const name = realName.split(' ').slice(1).join(' ') diff --git a/components/infoModal.vue b/components/infoModal.vue index 741f909..9141637 100644 --- a/components/infoModal.vue +++ b/components/infoModal.vue @@ -45,7 +45,7 @@ - + Result for «{{ searchTerm }}» @@ -54,8 +54,8 @@

{{ error }}

-
Info should be displayed in a few seconds
Gathering data...
+
Info should be displayed in a few seconds
{{ info.title }} diff --git a/pages/index.vue b/pages/index.vue index 4bb8979..33dfa65 100755 --- a/pages/index.vue +++ b/pages/index.vue @@ -74,7 +74,7 @@ - + more diff --git a/pages/localPage.vue b/pages/localPage.vue index e7bae56..608b9b8 100644 --- a/pages/localPage.vue +++ b/pages/localPage.vue @@ -171,7 +171,13 @@ console.log(`[${(new Date()).toLocaleTimeString()}]: Requested to play ${path}. Sending...`) // No need to get through store. - axios.get(`openThis?type=video&path=${path}&dir=${this.$store.state.currentDir}`).then((res) => { + axios.get(`openThis`, { + params: { + type: 'video', + path: path, + dir: this.$store.state.currentDir + } + }).then((res) => { if (res.status !== 200) { console.log('An error occurred: request to open file ended with a status ' + res.status + '.') } this.$store.dispatch('appendHistory', { @@ -183,7 +189,13 @@ delThis (path) { console.log(`[${(new Date()).toLocaleTimeString()}]: Requested to delete ${path}. Sending...`) - axios.get(`openThis?type=delete&path=${path}&dir=${this.$store.state.currentDir}`).then((res) => { + axios.get(`openThis`, { + params: { + type: 'delete', + path: path, + dir: this.$store.state.currentDir + } + }).then((res) => { if (res.status !== 200) { console.log('An error occurred: request to delete file ended with a status ' + res.status + '.') } this.$store.dispatch('appendHistory', { diff --git a/store/index.js b/store/index.js index 414b4ed..ef05cfe 100644 --- a/store/index.js +++ b/store/index.js @@ -439,12 +439,13 @@ const store = new Vuex.Store({ commit('setRefreshingLocal') commit('setLocalFiles', data) }, - async resetLocal ({state, commit}) { + async resetLocal ({state, commit, dispatch}) { log(`Resetting local information...`) commit('setResettingLocal') axios.get(`resetLocal?dir=${state.currentDir}`).then(() => { + dispatch('refreshLocal') log(`Reset completed.`) }).catch((err) => { log('An error occurred while resetting.\n' + err)