mirror of
https://github.com/tobychui/zoraxy.git
synced 2025-08-06 13:18:30 +02:00
Added null check on front-end
- Added null check on TlsOption on front-end
This commit is contained in:
@@ -1423,11 +1423,17 @@
|
|||||||
|
|
||||||
/* ------------ TLS ------------ */
|
/* ------------ TLS ------------ */
|
||||||
updateTlsResolveList(uuid);
|
updateTlsResolveList(uuid);
|
||||||
editor.find(".Tls_EnableSNI").prop("checked", !subd.TlsOptions.DisableSNI);
|
if (subd.TlsOptions){
|
||||||
|
editor.find(".Tls_EnableSNI").prop("checked", !subd.TlsOptions.DisableSNI);
|
||||||
editor.find(".Tls_EnableLegacyCertificateMatching").prop("checked", !subd.TlsOptions.DisableLegacyCertificateMatching);
|
editor.find(".Tls_EnableLegacyCertificateMatching").prop("checked", !subd.TlsOptions.DisableLegacyCertificateMatching);
|
||||||
editor.find(".Tls_EnableAutoHTTPS").prop("checked", !!subd.TlsOptions.EnableAutoHTTPS);
|
editor.find(".Tls_EnableAutoHTTPS").prop("checked", !!subd.TlsOptions.EnableAutoHTTPS);
|
||||||
|
}else{
|
||||||
|
//Use default options
|
||||||
|
editor.find(".Tls_EnableSNI").prop("checked", true);
|
||||||
|
editor.find(".Tls_EnableLegacyCertificateMatching").prop("checked", true);
|
||||||
|
editor.find(".Tls_EnableAutoHTTPS").prop("checked", false);
|
||||||
|
}
|
||||||
|
|
||||||
editor.find(".Tls_EnableSNI").off("change").on("change", function() {
|
editor.find(".Tls_EnableSNI").off("change").on("change", function() {
|
||||||
saveTlsConfigs(uuid);
|
saveTlsConfigs(uuid);
|
||||||
});
|
});
|
||||||
|
Reference in New Issue
Block a user