mirror of
https://github.com/netchx/netch.git
synced 2026-05-11 23:45:06 +08:00
fix: let SettingForm skip saving DNS value when UseCustomDNS is not enabled
This commit is contained in:
@@ -120,7 +120,11 @@ namespace Netch.Forms
|
||||
|
||||
BindTextBox(TUNTAPDNSTextBox,
|
||||
s => !UseCustomDNSCheckBox.Checked || DNS.TrySplit(s, out _, 2),
|
||||
s => Global.Settings.TUNTAP.DNS = DNS.Split(s).ToList(),
|
||||
s =>
|
||||
{
|
||||
if (UseCustomDNSCheckBox.Checked)
|
||||
Global.Settings.TUNTAP.DNS = DNS.Split(s).ToList();
|
||||
},
|
||||
DNS.Join(Global.Settings.TUNTAP.DNS));
|
||||
|
||||
BindCheckBox(ProxyDNSCheckBox,
|
||||
|
||||
Reference in New Issue
Block a user