Logout fix

Signed-off-by: Marco Casella <marco.casella@gmail.com>