edited the visited reference