Feature(custom): trim trailing slash from host url in lsky delete api #456

This commit is contained in:
Kuingsmile
2026-01-13 21:27:44 +08:00
parent ab1cd59c0c
commit 2847384de4
2 changed files with 2 additions and 1 deletions

View File

@@ -27,7 +27,7 @@ export default class LskyplistApi {
rejectUnauthorized: false,
})
try {
const response: AxiosResponse = await axios.delete(`${host}/api/v1/images/${hash}`, {
const response: AxiosResponse = await axios.delete(`${host.replace(/\/$/, '')}/api/v1/images/${hash}`, {
headers: v2Headers,
timeout: 30000,
httpsAgent: requestAgent,

View File

@@ -295,6 +295,7 @@ interface IGitHubConfig {
repo: string
token: string
path?: string
webPath?: string
customUrl?: string
branch: string
}