def string_to_scopes(scopes):
 if (not scopes):
  return []
 elif isinstance(scopes, six.string_types):
  return scopes.split(' ')
 else:
  return scopes

def string_to_scopes ( scopes ) : if ( not scopes ) : return [ ] elif isinstance ( scopes , six . string_types ) : return scopes . split ( ' ' ) else : return scopes
converts stringifed scope value to a list .