mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-02-06 00:16:02 +01:00
Removed unneeded mixin
This commit is contained in:
parent
88078ff813
commit
9350c5513e
@ -65,10 +65,8 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import Path from 'path'
|
import Path from 'path'
|
||||||
import apiRequestHelpers from '@/mixins/apiRequestHelpers'
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
mixins: [apiRequestHelpers],
|
|
||||||
props: {
|
props: {
|
||||||
item: {
|
item: {
|
||||||
type: Object,
|
type: Object,
|
||||||
@ -137,7 +135,7 @@ export default {
|
|||||||
this.error = ''
|
this.error = ''
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const searchQueryString = this.buildQuerystring({
|
const searchQueryString = new URLSearchParams({
|
||||||
title: this.itemData.title,
|
title: this.itemData.title,
|
||||||
author: this.itemData.author,
|
author: this.itemData.author,
|
||||||
provider: this.provider
|
provider: this.provider
|
||||||
@ -147,9 +145,9 @@ export default {
|
|||||||
if (bestCandidate) {
|
if (bestCandidate) {
|
||||||
this.itemData = {
|
this.itemData = {
|
||||||
...this.itemData,
|
...this.itemData,
|
||||||
title: bestCandidate?.title,
|
title: bestCandidate.title,
|
||||||
author: bestCandidate?.author,
|
author: bestCandidate.author,
|
||||||
series: (bestCandidate?.series || [])[0]?.series
|
series: (bestCandidate.series || [])[0]?.series
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.error = this.$strings.ErrorUploadFetchMetadataNoResults
|
this.error = this.$strings.ErrorUploadFetchMetadataNoResults
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
export default {
|
|
||||||
methods: {
|
|
||||||
buildQuerystring(obj, opts = { includePrefix: false }) {
|
|
||||||
let querystring = Object
|
|
||||||
.entries(obj)
|
|
||||||
.map(([key, val]) => `${encodeURIComponent(key)}=${encodeURIComponent(val)}`)
|
|
||||||
.join('&')
|
|
||||||
|
|
||||||
return (opts.includePrefix ? '?' : '').concat(querystring)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user