mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-05 05:34:22 -07:00
Fix #10394 return condition.
This commit is contained in:
parent
bb7588df0b
commit
2078725242
1 changed files with 1 additions and 1 deletions
|
@ -144,7 +144,7 @@ class Sysrc(object):
|
||||||
if self.value is None:
|
if self.value is None:
|
||||||
return self.name in conf
|
return self.name in conf
|
||||||
else:
|
else:
|
||||||
return conf[self.name] == '"%s"' % self.value
|
return self.name in conf and conf[self.name] == '"%s"' % self.value
|
||||||
|
|
||||||
def contains(self):
|
def contains(self):
|
||||||
(rc, out, err) = self.run_sysrc('-n', self.name)
|
(rc, out, err) = self.run_sysrc('-n', self.name)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue