remove double read of "path"

path is already read in line 444, don't reread the file here, but use the existing content
This commit is contained in:
Robin Roth 2016-03-22 07:50:04 +01:00
parent 9005f91bb0
commit fea5500605

View file

@ -466,7 +466,7 @@ class Facts(object):
elif path == '/etc/SuSE-release':
if 'open' in data.lower():
data = data.splitlines()
distdata = get_file_content(path).split('\n')[0]
distdata = data[0]
self.facts['distribution'] = distdata.split()[0]
for line in data:
release = re.search('CODENAME *= *([^\n]+)', line)