def get_deadlink()

in modify-deadlink.py [0:0]


def get_deadlink(file_path, search_dir):
    results = []
    if os.path.isfile(file_path):  # Check if it's a valid file
        with open(file_path, 'r') as file:
            for line in file:
                line = line.strip()  # Remove possible spaces and newline characters
                # Call find_file for each line and pass the current line content
                results.extend(find_file(line, search_dir, line))  # Append the result of each line to the results list
    else:
        print(f"{file_path} is not a valid file.")  # Print if the file is invalid

    return results