def _get_filename(base_url, content_type=None, content_disposition=None):
    """
    Determine an output filename to use for the download.
    """
    filename = None
    if content_disposition:
        filename = _get_filename_from_content_disposition(content_disposition)
        if filename is not None:
            return filename

    return _get_filename_from_url(base_url, content_type)

    Determine an output filename to use for the download.
    
apistar/client/decoders.py