Get default resolver name.

    :param str name: if given, change the default name.
    :raises: NameError if name given and not in registered resolvers.
    :rtype: str

def defaultname(name=None):
    """Get default resolver name.

    :param str name: if given, change the default name.
    :raises: NameError if name given and not in registered resolvers.
    :rtype: str"""

    if name is None:
        name = _RESOLVER_REGISTRY.default

    else:
        _RESOLVER_REGISTRY.default = name

    return name