This thread is resolved. Here is a description of the problem and solution.
The user was having an issue with the plugin, when he switched to the secondary language in the admin top bar, the logout link does not work anymore and only redirects to the homepage without logging out the user.
It is a compatibility issue and we could solve it by patching the plugin. The patch is changing or commenting line 151 of the same file "/classes/plugin.php" with the following.
return $this->user_trailingslashit( site_url( '/', $scheme ) . $this->new_login_slug() );
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.