Use regex variable in eos_user.py (#23797)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
This commit is contained in:
parent
91644167c9
commit
527a7762e1
1 changed files with 1 additions and 1 deletions
|
@ -203,7 +203,7 @@ def map_config_to_obj(module):
|
|||
|
||||
for user in set(match):
|
||||
regex = r'username %s .+$' % user
|
||||
cfg = re.findall(r'username %s .+$' % user, data, re.M)
|
||||
cfg = re.findall(regex, data, re.M)
|
||||
cfg = '\n'.join(cfg)
|
||||
obj = {
|
||||
'username': user,
|
||||
|
|
Loading…
Reference in a new issue