From 6ccbfde76e951652fdafa3bd602bc6c2e6f28c9d Mon Sep 17 00:00:00 2001 From: Daniil Baturin Date: Wed, 28 Feb 2018 14:43:06 +0100 Subject: Fix return_values function (return a list instead of a raw string). --- python/vyos/config.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'python/vyos/config.py') diff --git a/python/vyos/config.py b/python/vyos/config.py index 6160d9a6b..6f544462c 100644 --- a/python/vyos/config.py +++ b/python/vyos/config.py @@ -117,7 +117,8 @@ class Config(object): else: try: out = self._run(self._make_command('returnValues', full_path)) - return out + values = out.split() + return list(map(lambda x: re.sub(r'^\'(.*)\'$', r'\1',x), values)) except VyOSError: return(default) -- cgit v1.2.3