def alias_get(indices=None, aliases=None, hosts=None, profile=None):
 es = _get_instance(hosts, profile)
 try:
  ret = es.indices.get_alias(index=indices, name=aliases)
  return ret
 except elasticsearch.exceptions.NotFoundError:
  return None
 return None

def alias_get ( indices = None , aliases = None , hosts = None , profile = None ) : es = _get_instance ( hosts , profile ) try : ret = es . indices . get_alias ( index = indices , name = aliases ) return ret except elasticsearch . exceptions . NotFoundError : return None return None
check for the existence of an alias and if it exists .