mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Merge pull request #47515 from rallytime/bp-47503
Back-port #47503 to 2018.3
This commit is contained in:
commit
bf79acfbc8
@ -225,7 +225,7 @@ def _switch(name, # pylint: disable=C0103
|
||||
if os.path.exists(config):
|
||||
with salt.utils.files.fopen(config, 'r') as ifile:
|
||||
for line in ifile:
|
||||
line = salt.utils.stringutils.to_unicode(line).rstrip('\n')
|
||||
line = salt.utils.stringutils.to_unicode(line)
|
||||
if not line.startswith('{0}='.format(rcvar)):
|
||||
nlines.append(line)
|
||||
continue
|
||||
|
Loading…
Reference in New Issue
Block a user