def METHOD_NAME(file_path):
    temp_buf = StringIO()
    updated = False
    with open(file_path) as fp:
        for line in fp:
            if line == "type: ref\n":
                temp_buf.write("type: base64\n")
                if not updated:  # only set updated once
                    updated = True
            else:
                temp_buf.write(line)
    if updated:
        print(">>> updating:", file_path)
        with open(file_path, "w") as fp:
            fp.write(temp_buf.getvalue())