fixing bug where the query to check if a visitor already existed was failing, and was letting everything through.