def _normalize_basedir(basedir=None):
 if isinstance(basedir, six.string_types):
  basedir = [x.strip() for x in basedir.split(',')]
 if (basedir is None):
  basedir = []
 if (not basedir):
  basedir = _get_yum_config_value('reposdir')
 if ((not isinstance(basedir, list)) or (not basedir)):
  raise SaltInvocationError('Could not determine any repo directories')
 return basedir

def _normalize_basedir ( basedir = None ) : if isinstance ( basedir , six . string_types ) : basedir = [ x . strip ( ) for x in basedir . split ( ',' ) ] if ( basedir is None ) : basedir = [ ] if ( not basedir ) : basedir = _get_yum_config_value ( 'reposdir' ) if ( ( not isinstance ( basedir , list ) ) or ( not basedir ) ) : raise SaltInvocationError ( 'Could not determine any repo directories' ) return basedir
takes a basedir argument as a string or a list .