don't add a check if it's the logout process
adding some search framework code