Plan visit bug fix