fix: remove trailing slash from admin.js

fixing 307 requests making a request to `/settings/`
This commit is contained in:
dni ⚡ 2024-04-04 07:54:21 +02:00 committed by Pavol Rusnak
parent 2066fff994
commit d64239f1ad

View File

@ -229,7 +229,7 @@ new Vue({
},
getAudit() {
LNbits.api
.request('GET', '/admin/api/v1/audit/', this.g.user.wallets[0].adminkey)
.request('GET', '/admin/api/v1/audit', this.g.user.wallets[0].adminkey)
.then(response => {
this.auditData = response.data
})
@ -241,7 +241,7 @@ new Vue({
LNbits.api
.request(
'GET',
'/admin/api/v1/settings/',
'/admin/api/v1/settings',
this.g.user.wallets[0].adminkey
)
.then(response => {
@ -262,7 +262,7 @@ new Vue({
LNbits.api
.request(
'PUT',
'/admin/api/v1/settings/',
'/admin/api/v1/settings',
this.g.user.wallets[0].adminkey,
data
)
@ -290,7 +290,7 @@ new Vue({
.confirmDialog('Are you sure you want to restore settings to default?')
.onOk(() => {
LNbits.api
.request('DELETE', '/admin/api/v1/settings/')
.request('DELETE', '/admin/api/v1/settings')
.then(response => {
this.$q.notify({
type: 'positive',
@ -306,7 +306,7 @@ new Vue({
})
},
downloadBackup() {
window.open('/admin/api/v1/backup/', '_blank')
window.open('/admin/api/v1/backup', '_blank')
}
}
})