Fix #47502: Remove an extraneous (accidentally introduced?) call to rstrip.

This commit is contained in:
Peter Sagerson 2018-05-06 12:03:25 -07:00 committed by rallytime
parent 17cfd4f7cf
commit 821dbb88a0
No known key found for this signature in database
GPG key ID: E8F1A4B90D0DEA19

View file

@ -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