From 4af935f5cddeb803716f73600ee9776ad9603e1b Mon Sep 17 00:00:00 2001 From: szkzn <30108874+szkzn@users.noreply.github.com> Date: Wed, 26 Jun 2024 14:03:24 +0800 Subject: [PATCH 1/2] Fixed compatibility bugs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 移除当没使用这些参数时,默认生成订阅后,强制附加的默认值 null,个别机场订阅会无法转换,因为附加了 exclued=null&include=null,在 MetaCubeX 魔改后端 、subconverter 官方上游后端最新 action commit 版本,转换时会触发不明的 has been ignored and will not be added,节点会全部被忽略,并且强制触发下载 header 行为 预期行为应该是在后端定义默认值和空值,不应该前端附加 --- src/views/Subconverter.vue | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/src/views/Subconverter.vue b/src/views/Subconverter.vue index e2fac9aee..b93588ce0 100644 --- a/src/views/Subconverter.vue +++ b/src/views/Subconverter.vue @@ -408,21 +408,17 @@ export default { this.form.insert; if (this.advanced === "2") { - if (this.form.remoteConfig !== "") { - this.customSubUrl += - "&config=" + encodeURIComponent(this.form.remoteConfig); + if (this.form.remoteConfig) { + this.customSubUrl += "&config=" + encodeURIComponent(this.form.remoteConfig); } - if (this.form.excludeRemarks !== "") { - this.customSubUrl += - "&exclude=" + encodeURIComponent(this.form.excludeRemarks); + if (this.form.excludeRemarks) { + this.customSubUrl += "&exclude=" + encodeURIComponent(this.form.excludeRemarks); } - if (this.form.includeRemarks !== "") { - this.customSubUrl += - "&include=" + encodeURIComponent(this.form.includeRemarks); + if (this.form.includeRemarks) { + this.customSubUrl += "&include=" + encodeURIComponent(this.form.includeRemarks); } - if (this.form.filename !== "") { - this.customSubUrl += - "&filename=" + encodeURIComponent(this.form.filename); + if (this.form.filename) { + this.customSubUrl += "&filename=" + encodeURIComponent(this.form.filename); } if (this.form.appendType) { this.customSubUrl += From e538e52f6ee7004fae1656712a71082e5457e9df Mon Sep 17 00:00:00 2001 From: szkzn <30108874+szkzn@users.noreply.github.com> Date: Wed, 26 Jun 2024 14:11:09 +0800 Subject: [PATCH 2/2] Keep style unified --- src/views/Subconverter.vue | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/views/Subconverter.vue b/src/views/Subconverter.vue index b93588ce0..ecc5657e2 100644 --- a/src/views/Subconverter.vue +++ b/src/views/Subconverter.vue @@ -409,16 +409,20 @@ export default { if (this.advanced === "2") { if (this.form.remoteConfig) { - this.customSubUrl += "&config=" + encodeURIComponent(this.form.remoteConfig); + this.customSubUrl += + "&config=" + encodeURIComponent(this.form.remoteConfig); } if (this.form.excludeRemarks) { - this.customSubUrl += "&exclude=" + encodeURIComponent(this.form.excludeRemarks); + this.customSubUrl += + "&exclude=" + encodeURIComponent(this.form.excludeRemarks); } if (this.form.includeRemarks) { - this.customSubUrl += "&include=" + encodeURIComponent(this.form.includeRemarks); + this.customSubUrl += + "&include=" + encodeURIComponent(this.form.includeRemarks); } if (this.form.filename) { - this.customSubUrl += "&filename=" + encodeURIComponent(this.form.filename); + this.customSubUrl += + "&filename=" + encodeURIComponent(this.form.filename); } if (this.form.appendType) { this.customSubUrl +=