fix: Fixed issue with can not disable cache in antiLeech (#10306)

This commit is contained in:
CityFun 2025-09-09 11:22:43 +08:00 committed by GitHub
parent feabc488fe
commit 50e99f1f4c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 5 deletions

View file

@ -81,8 +81,8 @@ type NginxCommonReq struct {
type NginxAntiLeechUpdate struct {
WebsiteID uint `json:"websiteID" validate:"required"`
Extends string `json:"extends" validate:"required"`
Return string `json:"return" validate:"required"`
Extends string `json:"extends"`
Return string `json:"return"`
Enable bool `json:"enable" `
ServerNames []string `json:"serverNames"`
Cache bool `json:"cache"`

View file

@ -240,9 +240,9 @@ const update = async (enable: boolean) => {
if (enable) {
updateDomainsString();
form.serverNames = form.domains.split('\n');
}
if (!checkReturn()) {
return;
if (!checkReturn()) {
return;
}
}
form.enable = enable;
loading.value = true;