summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/vyos/config.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/python/vyos/config.py b/python/vyos/config.py
index 5af830480..bcf04225b 100644
--- a/python/vyos/config.py
+++ b/python/vyos/config.py
@@ -280,8 +280,8 @@ class Config(object):
else:
try:
out = self._run(self._make_command('returnValues', full_path))
- values = out.split()
- return list(map(lambda x: re.sub(r'^\'(.*)\'$', r'\1',x), values))
+ values = re.findall(r"\'(.*?)\'", out)
+ return values
except VyOSError:
return(default)
@@ -309,8 +309,8 @@ class Config(object):
if self.is_tag(path):
try:
out = self._run(self._make_command('listNodes', full_path))
- values = out.split()
- return list(map(lambda x: re.sub(r'^\'(.*)\'$', r'\1',x), values))
+ values = re.findall(r"\'(.*?)\'", out)
+ return values
except VyOSError:
return(default)
else: