mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-08-04 02:05:06 +02:00
Update:API endpoints for library and library item scan updated to POST requests
This commit is contained in:
parent
c93f17051a
commit
b957e1a36b
6 changed files with 9 additions and 9 deletions
|
@ -662,7 +662,7 @@ export default {
|
|||
const axios = this.$axios || this.$nuxt.$axios
|
||||
this.processing = true
|
||||
axios
|
||||
.$get(`/api/items/${this.libraryItemId}/scan`)
|
||||
.$post(`/api/items/${this.libraryItemId}/scan`)
|
||||
.then((data) => {
|
||||
var result = data.result
|
||||
if (!result) {
|
||||
|
|
|
@ -129,7 +129,7 @@ export default {
|
|||
rescan() {
|
||||
this.rescanning = true
|
||||
this.$axios
|
||||
.$get(`/api/items/${this.libraryItemId}/scan`)
|
||||
.$post(`/api/items/${this.libraryItemId}/scan`)
|
||||
.then((data) => {
|
||||
this.rescanning = false
|
||||
var result = data.result
|
||||
|
|
|
@ -66,7 +66,7 @@ export const getters = {
|
|||
|
||||
export const actions = {
|
||||
requestLibraryScan({ state, commit }, { libraryId, force }) {
|
||||
return this.$axios.$get(`/api/libraries/${libraryId}/scan`, { params: { force } })
|
||||
return this.$axios.$post(`/api/libraries/${libraryId}/scan?force=${force ? 1 : 0}`)
|
||||
},
|
||||
loadFolders({ state, commit }) {
|
||||
if (state.folders.length) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue