remove state machine logic, use nokogiri straightaway