fix(plugin): ensure endpoints with / works in plugin
This commit is contained in:
parent
dc5dd81358
commit
dc5ae7a7b1
@ -147,6 +147,11 @@ function addButton() {
|
|||||||
|
|
||||||
console.log(prompt);
|
console.log(prompt);
|
||||||
|
|
||||||
|
// TODO trim the ending / from endpoint is there is
|
||||||
|
if (endpoint.endsWith("/")) {
|
||||||
|
endpoint = endpoint.slice(0, -1);
|
||||||
|
}
|
||||||
|
|
||||||
const apiRoute = endpoint + "/api/upload"
|
const apiRoute = endpoint + "/api/upload"
|
||||||
// const userId = apiKey
|
// const userId = apiKey
|
||||||
try {
|
try {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user