New features in the onLogout AJAX handler