Merge pull request #1851 from Pinkbyte/distribution_fix

Fix distribution detection - return string instead of functions
pull/1845/merge
Michael DeHaan 12 years ago
commit f095f7c8c5

@ -96,10 +96,10 @@ def get_distribution():
''' return the distribution name ''' ''' return the distribution name '''
if platform.system() == 'Linux': if platform.system() == 'Linux':
try: try:
distribution = platform.linux_distribution()[0].capitalize distribution = platform.linux_distribution()[0].capitalize()
except: except:
# FIXME: MethodMissing, I assume? # FIXME: MethodMissing, I assume?
distribution = platform.dist()[0].capitalize distribution = platform.dist()[0].capitalize()
else: else:
distribution = None distribution = None
return distribution return distribution

Loading…
Cancel
Save