def METHOD_NAME(filename, fallback):
    """Return a secure version of a filename.
    This removes possibly dangerous characters and also converts the
    filename to plain ASCII for maximum compatibility. It should only
    be used for file system storage, since especially filenames written
    in asian languages likely become useless when stripping anything
    that's not ASCII; use :func:`secure_client_filename` for client-facing
    filenames.
    :param filename: A filename
    :param fallback: The filename to use if there were no safe chars
                     in the original filename.
    """
    if not filename:
        return fallback
    filename = _secure_filename(str_to_ascii(filename))
    filename, ext = os.path.splitext(filename)
    filename = f'{filename[:150]}{ext}'
    return filename or fallback