How to override a plugin function wrapped in a class?

if the modification is called in the action admin_menu you can come just after, in order to correct the menu with some code like this :

add_action("admin_menu", function () {

    $parent_file="parent.php";
    $full_url = add_query_arg( 'action', 'action-name', admin_url( 'users.php' ) );


    global $submenu;


    // searching the last submenu
    $last = array_pop($submenu[$parent_file]);

    // correcting the URL
    $last[2] = $full_url;

    // replacing in the array
    $submenu[$parent_file][] = $last;

}, 20);
// default priority (used by the plugin) is 10, so I choose 20 to be sur that it comes after the plugin

tech