Update api.tsx
This commit is contained in:
parent
39549f0b94
commit
0dbcc7854b
1 changed files with 3 additions and 2 deletions
|
|
@ -65,8 +65,9 @@ class Api {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
updateUncap(resource: 'characters'|'weapons'|'summons', id: string, value: number) {
|
updateUncap(resource: 'character'|'weapon'|'summon', id: string, value: number) {
|
||||||
const resourceUrl = `${this.url}/${resource}/update_uncap`
|
const pluralized = resource + 's'
|
||||||
|
const resourceUrl = `${this.url}/${pluralized}/update_uncap`
|
||||||
return axios.post(resourceUrl, {
|
return axios.post(resourceUrl, {
|
||||||
[resource]: {
|
[resource]: {
|
||||||
id: id,
|
id: id,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue