summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriyEshenko <snooppy@mail.ua>2019-09-29 22:16:58 +0000
committerJohn Estabrook <jestabro@sentrium.io>2019-11-19 10:16:08 -0600
commitf2013266f617b9ef7236f80bd134112973167d06 (patch)
treedb254bb7df71d98596bb989cdc49b4d62b2fad4c
parent8993577a9da52b4e89918f7355aed09a8326618c (diff)
downloadvyos-1x-f2013266f617b9ef7236f80bd134112973167d06.tar.gz
vyos-1x-f2013266f617b9ef7236f80bd134112973167d06.zip
[vyos-hostsd] T1701 Fix check for delete domain-name and domain-search
(cherry picked from commit d1848a9f9447408deac451edf6392b8351ef6f64)
-rwxr-xr-xsrc/services/vyos-hostsd4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/services/vyos-hostsd b/src/services/vyos-hostsd
index e7ecd8573..5c2ea71c8 100755
--- a/src/services/vyos-hostsd
+++ b/src/services/vyos-hostsd
@@ -166,9 +166,9 @@ def delete_name_servers(data, tag):
def set_host_name(state, data):
if data['host_name']:
state['host_name'] = data['host_name']
- if data['domain_name']:
+ if 'domain_name' in data:
state['domain_name'] = data['domain_name']
- if data['search_domains']:
+ if 'search_domains' in data:
state['search_domains'] = data['search_domains']
def get_name_servers(state, tag):